home *** CD-ROM | disk | FTP | other *** search
/ Collection of Tools & Utilities / Collection of Tools and Utilities.iso / network / pctkn_v1.zip / PC_TOKEN.ASM < prev    next >
Assembly Source File  |  1994-07-11  |  77KB  |  2,091 lines

  1. ;***************************************************************
  2. ;*    PC_TOKEN.ASM by Andrew Lee NCU M.E. R.O.C. 1994          *
  3. ;*    E-Mail Address : u330633@sparc12.ncu.edu.tw (Internet)   *
  4. ;*    Postal Address : National Central Univ.                  *
  5. ;*                     Mechanical Dept. 4B, R.O.C.             *
  6. ;***************************************************************
  7.  
  8.                 TITLE   Asynchronous Serial Communication
  9.         DOSSEG
  10. KBDAT        EQU    60h                ;Keyboard Buffer
  11. KBSTATUS    EQU    64h                ;Keyboard Status
  12. PICIMR        EQU    21h                ;PIC IMR
  13. SEND_PORT    EQU    2f8h                ;COM2
  14. RCV_PORT    EQU    3f8h                ;COM1
  15. SOUND_SWITCH    EQU    61h                ;8255
  16. SOUND_PORT    EQU    42h                ;8254 Counter2
  17. SOUND_CONTROL    EQU    43h                ;8254 Command Word
  18. GET_MODE    EQU    0h                ;GPSCR MODE
  19. PUT_MODE    EQU    1h                ;GPSCR MODE
  20. YES        EQU    1h                ;Boolen Value
  21. NO        EQU    0h                ;Boolen Value
  22. F1        EQU    1                ;Function Key ID
  23. F2        EQU    2                ;Function Key ID
  24. F3        EQU    3                ;Function Key ID
  25. F4        EQU    4                ;Function Key ID
  26. RETURN        EQU    5                ;Function Key ID
  27. BACK        EQU    6                ;Function Key ID
  28. ESCAPE        EQU    7                ;Function Key ID
  29. NOTHING         EQU     20                              ;Function Key ID
  30.  
  31. NULL            EQU     0                               ;Signal ID
  32. ETX             EQU     3                               ;Signal ID
  33. CAN             EQU     24                              ;Signal ID
  34. DLE             EQU     16                              ;Signal ID
  35. SOH             EQU     1                               ;Signal ID
  36. ETB             EQU     23                              ;Signal ID
  37. NAK             EQU     21                              ;Signal ID
  38. ACK             EQU     6                               ;Signal ID
  39.  
  40.         .MODEL    SMALL
  41.         .STACK
  42.  
  43. ;-------------------------------------------------------------------------------
  44. ;    DATA SEGMENT
  45. ;-------------------------------------------------------------------------------
  46.         .DATA
  47.  
  48. MAIN_SCR    DB    '░',23,'░',23,'░',23,'░',23,'░',23,'░',23,'░',23,'░',23
  49.         DB    '░',23,'░',23,'░',23,'░',23,'░',23,'░',23,'░',23,'░',23
  50.         DB    '░',23,'░',23,'░',23,'░',23,'░',23,'░',23,'░',23,'░',23
  51.         DB    '░',23,'░',23,'░',23,'░',23,'░',23,'░',23,'░',23,'░',23
  52.         DB    '░',23,'░',23,'░',23,'░',23,'░',23,'░',23,'░',23,'░',23
  53.         DB    '░',23,'░',23,'░',23,'░',23,'░',23,'░',23,'░',23,'░',23
  54.         DB    '░',23,'░',23,'░',23,'░',23,'░',23,'░',23,'░',23,'░',23
  55.         DB    '░',23,'░',23,'░',23,'░',23,'░',23,'░',23,'░',23,'░',23
  56.         DB    '░',23,'░',23,'░',23,'░',23,'░',23,'░',23,'░',23,'░',23
  57.         DB    '░',23,'░',23,'░',23,'░',23,'░',23,'░',23,'░',23,'░',23
  58.         DB    '░',23,'╔',15,'═',15,'═',15,' ',15,'[',15,'|',15,']',15
  59.         DB    ' ',15,'S',15,'e',15,'n',15,'d',15,'e',15,'r',15,'(',15
  60.         DB    ' ',15,')',15,' ',15,'═',15,'═',15,'═',15,'═',15,'═',15
  61.         DB    '═',15,'═',15,'═',15,'═',15,'═',15,'═',15,'═',15,'═',15
  62.         DB    '═',15,'═',15,'═',15,'═',15,'═',15,'═',15,'═',15,'═',15
  63.         DB    '═',15,'═',15,'═',15,'═',15,'═',15,'═',15,'═',15,'═',15
  64.         DB    '═',15,'═',15,'═',15,'═',15,'═',15,'═',15,'═',15,'═',15
  65.         DB    '═',15,'═',15,'═',15,'═',15,'═',15,'═',15,'═',15,'═',15
  66.         DB    '═',15,'═',15,'═',15,'═',15,'═',15,'═',15,'═',15,'═',15
  67.         DB    '═',15,'═',15,'═',15,'═',15,'╗',15,'░',23,'░',23,'░',23
  68.         DB    '░',23,'║',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  69.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  70.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  71.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  72.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  73.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  74.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  75.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  76.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  77.         DB    ' ',15,' ',15,' ',15,' ',15,'║',15,'▓',24,'▓',24,'░',23
  78.         DB    '░',23,'║',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  79.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  80.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  81.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  82.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  83.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  84.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  85.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  86.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  87.         DB    ' ',15,' ',15,' ',15,' ',15,'║',15,'▓',24,'▓',24,'░',23
  88.         DB    '░',23,'║',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  89.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  90.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  91.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  92.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  93.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  94.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  95.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  96.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  97.         DB    ' ',15,' ',15,' ',15,' ',15,'║',15,'▓',24,'▓',24,'░',23
  98.         DB    '░',23,'║',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  99.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  100.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  101.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  102.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  103.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  104.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  105.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  106.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  107.         DB    ' ',15,' ',15,' ',15,' ',15,'║',15,'▓',24,'▓',24,'░',23
  108.         DB    '░',23,'║',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  109.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  110.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  111.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  112.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  113.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  114.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  115.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  116.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  117.         DB    ' ',15,' ',15,' ',15,' ',15,'║',15,'▓',24,'▓',24,'░',23
  118.         DB    '░',23,'║',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  119.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  120.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  121.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  122.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  123.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  124.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  125.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  126.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  127.         DB    ' ',15,' ',15,' ',15,' ',15,'║',15,'▓',24,'▓',24,'░',23
  128.         DB    '░',23,'║',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  129.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  130.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  131.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  132.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  133.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  134.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  135.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  136.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  137.         DB    ' ',15,' ',15,' ',15,' ',15,'║',15,'▓',24,'▓',24,'░',23
  138.         DB    '░',23,'╟',15,'─',15,'─',15,' ',15,'[',15,'|',15,']',15
  139.         DB    ' ',15,'R',15,'e',15,'c',15,'e',15,'i',15,'v',15,'e',15
  140.         DB    'r',15,' ',15,'─',15,'─',15,'─',15,'─',15,'─',15,'─',15
  141.         DB    '─',15,'─',15,'─',15,'─',15,'─',15,'─',15,'─',15,'─',15
  142.         DB    '─',15,'─',15,'─',15,'─',15,'─',15,'─',15,'─',15,'─',15
  143.         DB    '─',15,'─',15,'─',15,'─',15,'─',15,'─',15,'─',15,'─',15
  144.         DB    '─',15,'─',15,'─',15,'─',15,'─',15,'─',15,'─',15,'─',15
  145.         DB    '─',15,'─',15,'─',15,'─',15,'─',15,'─',15,'─',15,'─',15
  146.         DB    '─',15,'─',15,'─',15,'─',15,'─',15,'─',15,'─',15,'─',15
  147.         DB    '─',15,'─',15,'─',15,'─',15,'╢',15,'▓',24,'▓',24,'░',23
  148.         DB    '░',23,'║',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  149.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  150.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  151.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  152.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  153.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  154.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  155.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  156.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  157.         DB    ' ',15,' ',15,' ',15,' ',15,'║',15,'▓',24,'▓',24,'░',23
  158.         DB    '░',23,'║',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  159.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  160.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  161.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  162.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  163.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  164.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  165.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  166.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  167.         DB    ' ',15,' ',15,' ',15,' ',15,'║',15,'▓',24,'▓',24,'░',23
  168.         DB    '░',23,'║',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  169.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  170.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  171.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  172.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  173.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  174.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  175.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  176.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  177.         DB    ' ',15,' ',15,' ',15,' ',15,'║',15,'▓',24,'▓',24,'░',23
  178.         DB    '░',23,'║',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  179.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  180.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  181.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  182.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  183.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  184.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  185.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  186.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  187.         DB    ' ',15,' ',15,' ',15,' ',15,'║',15,'▓',24,'▓',24,'░',23
  188.         DB    '░',23,'║',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  189.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  190.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  191.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  192.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  193.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  194.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  195.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  196.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  197.         DB    ' ',15,' ',15,' ',15,' ',15,'║',15,'▓',24,'▓',24,'░',23
  198.         DB    '░',23,'║',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  199.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  200.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  201.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  202.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  203.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  204.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  205.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  206.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  207.         DB    ' ',15,' ',15,' ',15,' ',15,'║',15,'▓',24,'▓',24,'░',23
  208.         DB    '░',23,'║',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  209.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  210.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  211.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  212.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  213.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  214.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  215.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  216.         DB    ' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15,' ',15
  217.         DB    ' ',15,' ',15,' ',15,' ',15,'║',15,'▓',24,'▓',24,'░',23
  218.         DB    '░',23,'╚',15,'═',15,'═',15,'═',15,'═',15,'═',15,'═',15
  219.         DB    '═',15,'═',15,'═',15,'═',15,'═',15,'═',15,'═',15,'═',15
  220.         DB    '═',15,'═',15,'═',15,'═',15,'═',15,'═',15,'═',15,'═',15
  221.         DB    '═',15,'═',15,'═',15,'═',15,'═',15,'═',15,'═',15,'═',15
  222.         DB    '═',15,'═',15,'═',15,'═',15,'═',15,'═',15,'═',15,'═',15
  223.         DB    '═',15,'═',15,'═',15,'═',15,'═',15,'═',15,'═',15,'═',15
  224.         DB    '═',15,'═',15,'═',15,'═',15,'═',15,'═',15,'═',15,'═',15
  225.         DB    '═',15,'═',15,'═',15,'═',15,'═',15,'═',15,'═',15,'═',15
  226.         DB    '═',15,'═',15,'═',15,'═',15,'═',15,'═',15,'═',15,'═',15
  227.         DB    '═',15,'═',15,'═',15,'═',15,'╝',15,'▓',24,'▓',24,'░',23
  228.         DB    '░',23,'░',23,'░',23,'▓',24,'▓',24,'▓',24,'▓',24,'▓',24
  229.         DB    '▓',24,'▓',24,'▓',24,'▓',24,'▓',24,'▓',24,'▓',24,'▓',24
  230.         DB    '▓',24,'▓',24,'▓',24,'▓',24,'▓',24,'▓',24,'▓',24,'▓',24
  231.         DB    '▓',24,'▓',24,'▓',24,'▓',24,'▓',24,'▓',24,'▓',24,'▓',24
  232.         DB    '▓',24,'▓',24,'▓',24,'▓',24,'▓',24,'▓',24,'▓',24,'▓',24
  233.         DB    '▓',24,'▓',24,'▓',24,'▓',24,'▓',24,'▓',24,'▓',24,'▓',24
  234.         DB    '▓',24,'▓',24,'▓',24,'▓',24,'▓',24,'▓',24,'▓',24,'▓',24
  235.         DB    '▓',24,'▓',24,'▓',24,'▓',24,'▓',24,'▓',24,'▓',24,'▓',24
  236.         DB    '▓',24,'▓',24,'▓',24,'▓',24,'▓',24,'▓',24,'▓',24,'▓',24
  237.         DB    '▓',24,'▓',24,'▓',24,'▓',24,'▓',24,'▓',24,'▓',24,'░',23
  238.         DB    '░',23,'░',23,'░',23,'░',23,'░',23,'░',23,'░',23,'░',23
  239.         DB    '░',23,'░',23,'░',23,'░',23,'░',23,'░',23,'░',23,'░',23
  240.         DB    '░',23,'░',23,'░',23,'░',23,'░',23,'░',23,'░',23,'░',23
  241.         DB    '░',23,'░',23,'░',23,'░',23,'░',23,'░',23,'░',23,'░',23
  242.         DB    '░',23,'░',23,'░',23,'░',23,'░',23,'░',23,'░',23,'░',23
  243.         DB    '░',23,'░',23,'░',23,'░',23,'░',23,'░',23,'░',23,'░',23
  244.         DB    '░',23,'░',23,'░',23,'░',23,'░',23,'░',23,'░',23,'░',23
  245.         DB    '░',23,'░',23,'░',23,'░',23,'░',23,'░',23,'░',23,'░',23
  246.         DB    '░',23,'░',23,'░',23,'░',23,'░',23,'░',23,'░',23,'░',23
  247.         DB    '░',23,'░',23,'░',23,'░',23,'░',23,'░',23,'░',23,'░',23
  248.         DB    '░',23,'░',23,'┌',31,'─',31,'─',31,'─',31,'─',31,'─',31
  249.         DB    '─',31,'─',31,'─',31,'─',31,'─',31,'─',31,'─',31,'─',31
  250.         DB    '─',31,'─',31,'─',31,'─',31,'─',31,'─',31,'─',31,'─',31
  251.         DB    '─',31,'─',31,'─',31,'┐',16,'░',23,'░',23,'┌',16,'─',16
  252.         DB    '─',16,' ',16,'D',31,'e',31,'s',31,'t',31,'i',31,'n',31
  253.         DB    'a',31,'t',31,'i',31,'o',31,'n',31,' ',16,'─',16,'─',16
  254.         DB    '─',16,'┐',31,'░',23,'░',23,'┌',31,'─',31,'─',31,'─',31
  255.         DB    '─',31,'─',31,'─',31,'─',31,'─',31,'─',31,'─',31,'─',31
  256.         DB    '─',31,'─',31,'─',31,'─',31,'─',31,'─',31,'─',31,'─',31
  257.         DB    '─',31,'─',31,'─',31,'─',31,'─',31,'┐',16,'░',23,'░',23
  258.                 DB      '░',23,'░',23,'│',31,' ',31,'C',31,'u',31,'r',31,'r',31
  259.         DB    'e',31,'n',31,'t',31,' ',31,'T',31,'i',31,'m',31,'e',31
  260.         DB    ' ',31,' ',31,' ',31,' ',31,' ',31,' ',31,' ',31,' ',31
  261.         DB    ' ',31,' ',31,' ',31,'│',16,'░',23,'░',23,'│',16,' ',31
  262.         DB    ' ',31,' ',31,' ',31,' ',31,' ',31,' ',31,' ',31,' ',31
  263.         DB    ' ',31,' ',31,' ',31,' ',31,' ',31,' ',31,' ',31,' ',31
  264.         DB    ' ',31,'│',31,'░',23,'░',23,'│',31,' ',31,'T',31,'a',31
  265.         DB    'l',31,'k',31,'e',31,'r',31,' ',31,'(',31,'R',31,'S',31
  266.         DB    '2',31,'3',31,'2',31,')',31,' ',31,'V',31,'e',31,'r',31
  267.         DB    ' ',31,'1',31,'.',31,'0',31,' ',31,'│',16,'░',23,'░',23
  268.         DB    '░',23,'░',23,'└',31,'─',16,'─',16,'─',16,'─',16,'─',16
  269.         DB    '─',16,'─',16,'─',16,'─',16,'─',16,'─',16,'─',16,'─',16
  270.         DB    '─',16,'─',16,'─',16,'─',16,'─',16,'─',16,'─',16,'─',16
  271.         DB    '─',16,'─',16,'─',16,'┘',16,'░',23,'░',23,'└',16,'─',31
  272.         DB    '─',31,'─',31,'─',31,'─',31,'─',31,'─',31,'─',31,'─',31
  273.         DB    '─',31,'─',31,'─',31,'─',31,'─',31,'─',31,'─',31,'─',31
  274.         DB    '─',31,'┘',31,'░',23,'░',23,'└',31,'─',16,'─',16,'─',16
  275.         DB    '─',16,'─',16,'─',16,'─',16,'─',16,'─',16,'─',16,'─',16
  276.         DB    '─',16,'─',16,'─',16,'─',16,'─',16,'─',16,'─',16,'─',16
  277.         DB    '─',16,'─',16,'─',16,'─',16,'─',16,'┘',16,'░',23,'░',23
  278.         DB    '░',23,'░',23,'░',23,'░',23,'░',23,'░',23,'░',23,'░',23
  279.         DB    '░',23,'░',23,'░',23,'░',23,'░',23,'░',23,'░',23,'░',23
  280.         DB    '░',23,'░',23,'░',23,'░',23,'░',23,'░',23,'░',23,'░',23
  281.         DB    '░',23,'░',23,'░',23,'░',23,'░',23,'░',23,'░',23,'░',23
  282.         DB    '░',23,'░',23,'░',23,'░',23,'░',23,'░',23,'░',23,'░',23
  283.         DB    '░',23,'░',23,'░',23,'░',23,'░',23,'░',23,'░',23,'░',23
  284.         DB    '░',23,'░',23,'░',23,'░',23,'░',23,'░',23,'░',23,'░',23
  285.         DB    '░',23,'░',23,'░',23,'░',23,'░',23,'░',23,'░',23,'░',23
  286.         DB    '░',23,'░',23,'░',23,'░',23,'░',23,'░',23,'░',23,'░',23
  287.         DB    '░',23,'░',23,'░',23,'░',23,'░',23,'░',23,'░',23,'░',23
  288.         DB    ' ',95,' ',95,'F',91,'1',91,'-',95,'S',95,'e',95,'n',95
  289.         DB    'd',95,' ',95,' ',95,'F',91,'2',91,'-',95,'M',95,'u',95
  290.         DB    's',95,'i',95,'c',95,'(',95,'X',95,')',95,' ',95,' ',95
  291.         DB    'F',91,'3',91,'-',95,'C',95,'L',95,'R',95,'_',95,'S',95
  292.         DB    'e',95,'n',95,'d',95,'e',95,'r',95,' ',95,' ',95,'F',91
  293.         DB    '4',91,'-',95,'C',95,'L',95,'R',95,'_',95,'R',95,'e',95
  294.         DB    'c',95,'e',95,'i',95,'v',95,'e',95,'r',95,' ',95,' ',95
  295.         DB    '<',95,' ',95,' ',95,' ',95,' ',95,' ',95,' ',95,' ',95
  296.         DB    ' ',95,' ',95,' ',95,' ',95,' ',95,' ',95,' ',95,' ',95
  297.         DB    ' ',95,' ',95,' ',95,' ',95,' ',95,'>',95,' ',95,' ',95
  298.  
  299. FONT        DB    000h,000h,000h,000h,000h,000h,000h,000h ;32
  300.         DB    000h,000h,000h,000h,000h,000h,000h,000h
  301.         DB    000h,000h,010h,030h,030h,030h,030h,030h ;33
  302.         DB    020h,000h,030h,030h,000h,000h,000h,000h
  303.         DB    000h,024h,06Ch,06Ch,048h,000h,000h,000h ;34
  304.         DB    000h,000h,000h,000h,000h,000h,000h,000h
  305.         DB    000h,000h,024h,06Ch,06Ch,0FEh,06Ch,06Ch ;35
  306.         DB    0FEh,06Ch,06Ch,048h,000h,000h,000h,000h
  307.         DB    000h,000h,010h,07Eh,0FCh,0D0h,0D0h,07Ch ;36
  308.         DB    016h,016h,07Eh,0FCh,010h,000h,000h,000h
  309.         DB    000h,006h,0C6h,0CCh,0CCh,018h,018h,030h ;37
  310.         DB    030h,066h,066h,0C6h,0C0h,000h,000h,000h
  311.         DB    000h,000h,018h,03Ch,024h,038h,018h,07Ah ;38
  312.         DB    0CCh,0CCh,0D6h,074h,000h,000h,000h,000h
  313.         DB    000h,018h,018h,008h,010h,000h,000h,000h ;39
  314.         DB    000h,000h,000h,000h,000h,000h,000h,000h
  315.         DB    000h,006h,00Ch,01Ch,018h,018h,018h,018h ;40
  316.         DB    018h,018h,01Ch,00Ch,006h,000h,000h,000h
  317.         DB    000h,0C0h,060h,070h,030h,030h,030h,030h ;41
  318.         DB    030h,030h,070h,060h,0C0h,000h,000h,000h
  319.         DB    000h,000h,000h,000h,06Ch,038h,0FEh,038h ;42
  320.         DB    06Ch,000h,000h,000h,000h,000h,000h,000h
  321.         DB    000h,000h,000h,010h,030h,030h,07Ch,0F8h ;43
  322.         DB    030h,030h,020h,000h,000h,000h,000h,000h
  323.         DB    000h,000h,000h,000h,000h,000h,000h,000h ;44
  324.         DB    000h,000h,030h,030h,010h,020h,000h,000h
  325.         DB    000h,000h,000h,000h,000h,07Eh,0FCh,000h ;45
  326.         DB    000h,000h,000h,000h,000h,000h,000h,000h
  327.         DB    000h,000h,000h,000h,000h,000h,000h,000h ;46
  328.         DB    000h,000h,030h,030h,000h,000h,000h,000h
  329.         DB    000h,006h,006h,00Ch,00Ch,018h,018h,030h ;47
  330.         DB    030h,060h,060h,0C0h,0C0h,000h,000h,000h
  331.         DB    000h,000h,07Ch,0FEh,0C6h,0C6h,0D6h,0D6h ;48
  332.         DB    0C6h,0C6h,0FEh,07Ch,000h,000h,000h,000h
  333.         DB    000h,000h,018h,078h,0D8h,018h,018h,018h ;49
  334.         DB    018h,018h,07Eh,0FCh,000h,000h,000h,000h
  335.         DB    000h,000h,038h,07Ch,0ECh,0CCh,00Ch,00Ch ;50
  336.         DB    01Ch,038h,07Eh,0FCh,000h,000h,000h,000h
  337.         DB    000h,000h,07Ch,0FEh,006h,006h,03Eh,07Eh ;51
  338.         DB    006h,006h,07Eh,0FCh,000h,000h,000h,000h
  339.         DB    000h,000h,044h,0CCh,0CCh,0CCh,0FEh,07Ch ;52
  340.         DB    00Ch,00Ch,00Ch,008h,000h,000h,000h,000h
  341.         DB    000h,000h,07Eh,0FCh,0C0h,0C0h,0FCh,07Eh ;53
  342.         DB    006h,006h,07Ch,0F8h,000h,000h,000h,000h
  343.                 DB      000h,000h,03Ch,07Eh,0E2h,0C0h,0FCh,0FCh ;54
  344.         DB    0C6h,0C6h,07Eh,03Ch,000h,000h,000h,000h
  345.         DB    000h,000h,07Eh,0FEh,006h,006h,00Ch,07Eh ;55
  346.         DB    018h,018h,030h,030h,000h,000h,000h,000h
  347.         DB    000h,000h,038h,07Ch,04Ch,04Ch,07Ch,0C6h ;56
  348.         DB    0C6h,0C6h,0FEh,07Ch,000h,000h,000h,000h
  349.         DB    000h,000h,07Ch,0FEh,0C6h,0C6h,0FEh,07Eh ;57
  350.         DB    006h,006h,01Eh,03Ch,000h,000h,000h,000h
  351.         DB    000h,000h,000h,030h,030h,000h,000h,000h ;58
  352.         DB    000h,030h,030h,000h,000h,000h,000h,000h
  353.         DB    000h,000h,000h,030h,030h,000h,000h,000h ;59
  354.         DB    000h,030h,030h,010h,020h,000h,000h,000h
  355.         DB    000h,006h,00Ch,018h,030h,060h,0C0h,0C0h ;60
  356.         DB    060h,030h,018h,00Ch,006h,000h,000h,000h
  357.         DB    000h,000h,000h,07Eh,0FCh,000h,07Eh,0FCh ;61
  358.         DB    000h,000h,000h,000h,000h,000h,000h,000h
  359.         DB    000h,0C0h,060h,030h,018h,00Ch,006h,006h ;62
  360.         DB    00Ch,018h,030h,060h,0C0h,000h,000h,000h
  361.         DB    000h,000h,07Ch,0C6h,0C6h,086h,00Ch,00Ch ;63
  362.         DB    018h,000h,018h,018h,000h,000h,000h,000h
  363.         DB    000h,000h,03Ch,07Eh,0C6h,0DEh,0DEh,0D6h ;64
  364.         DB    0D6h,0DEh,0DEh,0C0h,07Eh,000h,000h,000h
  365.         DB    000h,000h,010h,038h,038h,038h,06Ch,06Ch ;65
  366.         DB    07Ch,0C6h,0C6h,084h,000h,000h,000h,000h
  367.         DB    000h,000h,0FCh,0FEh,0C6h,0C6h,0FCh,0C6h ;66
  368.         DB    0C6h,0C6h,0FEh,0FCh,000h,000h,000h,000h
  369.         DB    000h,000h,07Eh,0FCh,0E0h,0C0h,0C0h,0C0h ;67
  370.         DB    0C0h,0E0h,0FEh,07Ch,000h,000h,000h,000h
  371.         DB    000h,000h,0F8h,0FCh,0CCh,0C6h,0C6h,0C6h ;68
  372.         DB    0C6h,0CCh,0FCh,0F8h,000h,000h,000h,000h
  373.         DB    000h,000h,0FEh,0FCh,0C0h,0C0h,0F8h,0F0h ;69
  374.         DB    0C0h,0C0h,0FEh,0FCh,000h,000h,000h,000h
  375.         DB    000h,000h,0FEh,0FCh,0C0h,0C0h,0F8h,0F0h ;70
  376.         DB    0C0h,0C0h,0C0h,080h,000h,000h,000h,000h
  377.         DB    000h,000h,07Eh,0FCh,0C0h,0C0h,0CEh,0DEh ;71
  378.         DB    0C6h,0C6h,0FEh,07Ch,000h,000h,000h,000h
  379.         DB    000h,000h,042h,0C6h,0C6h,0C6h,0FEh,0FEh ;72
  380.         DB    0C6h,0C6h,0C6h,084h,000h,000h,000h,000h
  381.         DB    000h,000h,07Eh,0FCh,030h,030h,030h,030h ;73
  382.         DB    030h,030h,07Eh,0FCh,000h,000h,000h,000h
  383.         DB    000h,000h,07Eh,0FCh,00Ch,00Ch,00Ch,00Ch ;74
  384.         DB    00Ch,04Ch,0FCh,078h,000h,000h,000h,000h
  385.         DB    000h,000h,042h,0C6h,0CCh,0D8h,0F0h,0F8h ;75
  386.         DB    0CCh,0C4h,0C6h,082h,000h,000h,000h,000h
  387.         DB    000h,000h,040h,0C0h,0C0h,0C0h,0C0h,0C0h ;76
  388.         DB    0C0h,0C0h,0FEh,0FCh,000h,000h,000h,000h
  389.         DB    000h,000h,082h,0C6h,0EEh,0D6h,0C6h,0C6h ;77
  390.         DB    0C6h,0C6h,0C6h,084h,000h,000h,000h,000h
  391.         DB    000h,000h,082h,0C6h,0E6h,0E6h,0F6h,0DEh ;78
  392.         DB    0CEh,0CEh,0C6h,082h,000h,000h,000h,000h
  393.         DB    000h,000h,07Ch,0FEh,0C6h,0C6h,0C6h,0C6h ;79
  394.         DB    0C6h,0C6h,0FEh,07Ch,000h,000h,000h,000h
  395.         DB    000h,000h,078h,0FCh,0C6h,0C6h,0C6h,0FCh ;80
  396.         DB    0F8h,0C0h,0C0h,080h,000h,000h,000h,000h
  397.         DB    000h,000h,07Ch,0FEh,0C6h,0C6h,0C6h,0D6h ;81
  398.         DB    0D6h,0CEh,0FEh,07Ch,006h,000h,000h,000h
  399.         DB    000h,000h,078h,0FCh,0C6h,0C6h,0C6h,0FCh ;82
  400.         DB    0F8h,0D8h,0CCh,086h,000h,000h,000h,000h
  401.         DB    000h,000h,07Eh,0FCh,0C0h,0C0h,0FCh,07Eh ;83
  402.         DB    006h,006h,07Eh,0FCh,000h,000h,000h,000h
  403.         DB    000h,000h,07Eh,0FCh,030h,030h,030h,030h ;84
  404.         DB    030h,030h,030h,020h,000h,000h,000h,000h
  405.         DB    000h,000h,042h,0C6h,0C6h,0C6h,0C6h,0C6h ;85
  406.         DB    0C6h,0C6h,0FEh,07Ch,000h,000h,000h,000h
  407.         DB    000h,000h,0C6h,0C6h,0C6h,06Ch,06Ch,06Ch ;86
  408.         DB    038h,038h,038h,010h,000h,000h,000h,000h
  409.         DB    000h,000h,052h,0D6h,0D6h,0D6h,0D6h,07Ch ;87
  410.         DB    06Ch,06Ch,06Ch,028h,000h,000h,000h,000h
  411.         DB    000h,000h,0C6h,0C6h,06Ch,06Ch,038h,038h ;88
  412.         DB    038h,038h,06Ch,0EEh,000h,000h,000h,000h
  413.         DB    000h,000h,042h,0C6h,06Ch,06Ch,038h,030h ;89
  414.         DB    030h,030h,030h,020h,000h,000h,000h,000h
  415.         DB    000h,000h,07Eh,0FCh,00Ch,018h,0FEh,030h ;90
  416.         DB    030h,060h,07Eh,0FCh,000h,000h,000h,000h
  417.         DB    000h,01Eh,01Ch,018h,018h,018h,018h,018h ;91
  418.         DB    018h,018h,018h,01Eh,01Ch,000h,000h,000h
  419.         DB    000h,0C0h,0C0h,060h,060h,030h,030h,018h ;92
  420.         DB    018h,00Ch,00Ch,006h,006h,000h,000h,000h
  421.         DB    000h,070h,0F0h,030h,030h,030h,030h,030h ;93
  422.         DB    030h,030h,030h,070h,0F0h,000h,000h,000h
  423.         DB    010h,06Ch,0C6h,000h,000h,000h,000h,000h ;94
  424.         DB    000h,000h,000h,000h,000h,000h,000h,000h
  425.         DB    000h,000h,000h,000h,000h,000h,000h,000h ;95
  426.         DB    000h,000h,000h,000h,000h,0FFh,000h,000h
  427.         DB    000h,018h,018h,010h,008h,000h,000h,000h ;96
  428.         DB    000h,000h,000h,000h,000h,000h,000h,000h
  429.         DB    000h,000h,000h,000h,000h,078h,0FCh,0CCh ;97
  430.         DB    0CCh,0DCh,0FCh,06Eh,000h,000h,000h,000h
  431.         DB    000h,000h,040h,0C0h,0C0h,0DCh,0FEh,0E6h ;98
  432.         DB    0C6h,0C6h,0FEh,07Ch,000h,000h,000h,000h
  433.         DB    000h,000h,000h,000h,000h,07Ch,0FEh,0C2h ;99
  434.         DB    0C0h,0C0h,0FCh,07Eh,000h,000h,000h,000h
  435.         DB    000h,000h,002h,006h,006h,076h,0FEh,0CEh ;100
  436.         DB    0C6h,0C6h,0FEh,07Eh,000h,000h,000h,000h
  437.         DB    000h,000h,000h,000h,000h,038h,07Ch,0C6h ;101
  438.         DB    0FEh,0C0h,0FEh,07Ch,000h,000h,000h,000h
  439.         DB    000h,000h,000h,01Ch,036h,036h,030h,0FCh ;102
  440.         DB    030h,030h,030h,020h,000h,000h,000h,000h
  441.         DB    000h,000h,000h,000h,000h,07Ch,0FEh,0C6h ;103
  442.         DB    0C6h,0C6h,07Eh,006h,07Eh,0FCh,000h,000h
  443.         DB    000h,000h,040h,0C0h,0C0h,0DCh,0FEh,0E6h ;104
  444.         DB    0C6h,0C6h,0C6h,084h,000h,000h,000h,000h
  445.         DB    000h,000h,000h,018h,000h,008h,018h,018h ;105
  446.         DB    018h,018h,018h,010h,000h,000h,000h,000h
  447.         DB    000h,000h,000h,018h,000h,008h,018h,018h ;106
  448.         DB    018h,058h,0D8h,0F8h,070h,000h,000h,000h
  449.         DB    000h,000h,040h,0C0h,0C0h,0C6h,0CCh,0D8h ;107
  450.         DB    0F8h,0CCh,0C6h,086h,000h,000h,000h,000h
  451.         DB    000h,000h,010h,030h,030h,030h,030h,030h ;108
  452.         DB    030h,030h,030h,020h,000h,000h,000h,000h
  453.         DB    000h,000h,000h,000h,000h,07Ch,0FEh,0D6h ;109
  454.         DB    0D6h,0D6h,0D6h,094h,000h,000h,000h,000h
  455.         DB    000h,000h,000h,000h,040h,0DCh,0FEh,0E6h ;110
  456.         DB    0C6h,0C6h,0C6h,084h,000h,000h,000h,000h
  457.         DB    000h,000h,000h,000h,000h,07Ch,0FEh,0C6h ;111
  458.         DB    0C6h,0C6h,0FEh,07Ch,000h,000h,000h,000h
  459.         DB    000h,000h,000h,000h,000h,07Ch,0FEh,0C6h ;112
  460.         DB    0C6h,0E6h,0FEh,0DCh,0C0h,080h,000h,000h
  461.         DB    000h,000h,000h,000h,000h,07Ch,0FEh,0C6h ;113
  462.         DB    0C6h,0CEh,0FEh,076h,006h,004h,000h,000h
  463.         DB    000h,000h,000h,000h,000h,040h,0FCh,0E6h ;114
  464.         DB    0C2h,0C0h,0C0h,080h,000h,000h,000h,000h
  465.         DB    000h,000h,000h,000h,000h,07Eh,0FCh,0C0h ;115
  466.         DB    0FEh,006h,07Eh,0FCh,000h,000h,000h,000h
  467.         DB    000h,000h,010h,030h,030h,07Eh,0FCh,030h ;116
  468.         DB    030h,030h,030h,020h,000h,000h,000h,000h
  469.         DB    000h,000h,000h,000h,000h,042h,0C6h,0C6h ;117
  470.         DB    0C6h,0C6h,0FEh,07Ch,000h,000h,000h,000h
  471.         DB    000h,000h,000h,000h,000h,0C6h,0C6h,06Ch ;118
  472.         DB    06Ch,038h,038h,010h,000h,000h,000h,000h
  473.         DB    000h,000h,000h,000h,000h,052h,0D6h,0D6h ;119
  474.         DB    06Ch,06Ch,06Ch,028h,000h,000h,000h,000h
  475.         DB    000h,000h,000h,000h,000h,082h,0C6h,06Ch ;120
  476.         DB    038h,038h,06Ch,0C6h,000h,000h,000h,000h
  477.         DB    000h,000h,000h,000h,000h,082h,0C6h,066h ;121
  478.         DB    03Ch,01Ch,018h,030h,060h,0C0h,000h,000h
  479.         DB    000h,000h,000h,000h,000h,07Eh,0FCh,00Ch ;122
  480.         DB    018h,030h,07Eh,0FCh,000h,000h,000h,000h
  481.         DB    000h,00Eh,01Ch,018h,018h,018h,030h,030h ;123
  482.         DB    018h,018h,018h,01Ch,00Eh,000h,000h,000h
  483.         DB    000h,000h,010h,030h,030h,030h,020h,010h ;124
  484.         DB    030h,030h,030h,020h,000h,000h,000h,000h
  485.         DB    000h,0E0h,070h,030h,030h,030h,018h,018h ;125
  486.         DB    030h,030h,030h,070h,0E0h,000h,000h,000h
  487.         DB    000h,076h,0DCh,000h,000h,000h,000h,000h ;126
  488.         DB    000h,000h,000h,000h,000h,000h,000h,000h
  489.         DB    000h,000h,010h,028h,06Ch,06Ch,0C6h,0C6h ;127
  490.         DB    0C6h,0C6h,0FEh,0FEh,000h,000h,000h,000h
  491.  
  492.         DB    000h,001h,07fh,005h,009h,031h,0c1h,00fh ;lee
  493.         DB    000h,001h,07fh,001h,001h,005h,002h,000h
  494.         DB    000h,000h,0fch,040h,030h,00eh,004h,0e0h
  495.         DB    040h,088h,0fch,000h,000h,000h,000h,000h
  496.         DB    000h,010h,010h,000h,0feh,000h,07ch,003h
  497.         DB    07ch,000h,07dh,046h,044h,07ch,044h,000h
  498.         DB    000h,020h,010h,000h,0e0h,020h,024h,0a8h
  499.         DB    0b0h,0a0h,030h,024h,026h,060h,020h,000h
  500.         DB    000h,081h,041h,002h,0f4h,02fh,044h,087h
  501.         DB    040h,021h,021h,022h,02ch,050h,08fh,000h
  502.         DB    000h,010h,0f8h,010h,002h,0fch,044h,0fch
  503.         DB    0a0h,030h,02ah,022h,01eh,000h,0feh,000h
  504.         DB    000h,014h,03fh,044h,07fh,004h,03fh,024h
  505.         DB    006h,0ffh,04dh,014h,025h,0c6h,04ch,000h
  506.         DB    000h,004h,024h,024h,0a4h,024h,084h,08ch
  507.         DB    004h,0feh,010h,0a0h,040h,020h,01ch,000h
  508.         DB    000h,009h,009h,011h,012h,032h,054h,098h
  509.         DB    010h,010h,010h,010h,010h,010h,010h,000h
  510.         DB    000h,000h,004h,0f7h,080h,080h,088h,0f7h
  511.         DB    080h,080h,084h,0f7h,080h,080h,080h,000h
  512.         DB    000h,002h,0ffh,088h,0ffh,081h,0ffh,088h
  513.         DB    0ffh,000h,03fh,024h,024h,024h,0ffh,000h
  514.         DB    000h,020h,020h,03eh,020h,040h,000h,03eh
  515.         DB    000h,000h,0f8h,048h,048h,048h,0feh,000h
  516.         DB    000h,001h,001h,001h,07fh,041h,041h,041h
  517.         DB    07fh,041h,001h,001h,001h,001h,001h,000h
  518.         DB    000h,000h,000h,004h,0feh,004h,004h,004h
  519.         DB    0fch,004h,000h,000h,000h,000h,000h,000h
  520.         DB    000h,001h,001h,01fh,011h,011h,011h,011h
  521.         DB    0ffh,001h,002h,004h,008h,030h,0c0h,000h
  522.         DB    000h,000h,010h,0f8h,010h,010h,010h,010h
  523.         DB    0feh,000h,080h,040h,030h,00eh,004h,000h
  524.         DB    000h,021h,022h,024h,027h,0fah,025h,023h
  525.         DB    020h,077h,0aah,022h,025h,028h,020h,000h
  526.         DB    000h,048h,048h,0d0h,07eh,048h,054h,0fch
  527.         DB    044h,0feh,044h,028h,010h,0aah,046h,000h
  528.         DB    000h,010h,010h,010h,017h,0fch,032h,03ah
  529.         DB    057h,052h,092h,014h,018h,010h,013h,000h
  530.         DB    000h,020h,028h,024h,0feh,020h,0a0h,0a4h
  531.         DB    0e4h,0a8h,0a8h,0b0h,052h,08ah,006h,000h
  532.         DB    000h,001h,001h,021h,021h,021h,03fh,021h
  533.         DB    001h,021h,021h,021h,021h,07fh,021h,000h
  534.         DB    000h,000h,000h,008h,008h,008h,0f8h,008h
  535.         DB    000h,004h,004h,004h,004h,0f6h,004h,000h
  536.         DB    000h,00fh,008h,008h,008h,00fh,008h,000h
  537.         DB    07eh,062h,062h,062h,062h,07eh,042h,000h
  538.         DB    000h,0e0h,020h,020h,020h,0e0h,020h,000h
  539.         DB    0fch,084h,084h,084h,084h,0fch,084h,000h
  540.         DB    000h,07fh,044h,07fh,008h,010h,025h,07ah
  541.         DB    010h,024h,0feh,010h,054h,054h,010h,000h
  542.         DB    000h,0fch,044h,0fch,004h,090h,0fch,090h
  543.         DB    0fch,090h,0fch,090h,090h,0fch,080h,000h
  544.         DB    000h,001h,001h,0ffh,001h,001h,03fh,000h
  545.         DB    000h,01fh,010h,010h,010h,01fh,010h,000h
  546.         DB    000h,000h,004h,0feh,000h,010h,0f8h,000h
  547.         DB    010h,0f8h,010h,010h,010h,0f0h,010h,000h
  548.         DB    000h,00fh,008h,00fh,008h,00fh,000h,03fh
  549.         DB    030h,030h,03fh,030h,030h,03fh,030h,000h
  550.         DB    000h,0f0h,010h,0f0h,010h,0f0h,000h,0fch
  551.         DB    004h,004h,0fch,004h,004h,0fch,004h,000h
  552.  
  553.  
  554. ;-------------------------------------------------------------------------------
  555. ;    CODE SEGMENT
  556. ;-------------------------------------------------------------------------------
  557.         .CODE
  558.  
  559. ;Storage for old interrupt routine
  560. ;===================================
  561. video_base    DW    ?
  562. old_1c_seg    DW    ?
  563. old_1c_off    DW    ?
  564. old_9_seg    DW    ?
  565. old_9_off    DW    ?
  566. old_b_seg    DW    ?
  567. old_b_off    DW    ?
  568. old_c_seg    DW    ?
  569. old_c_off    DW    ?
  570.  
  571. ; The following is for song
  572. ;===================================
  573. song_index      DB      'X1234'                         ;Index
  574. song_sign       DB      ?,95                            ;Index Char on Screen
  575. song_ptr        DW      0h                              ;Pointer of Song Addr
  576. song_flag       DB      0h                              ;Music On or Off
  577. song_pointer    DW      0h                              ;Pointer of Song Data
  578. song_frequency  DW      0h                              ;Freq. Divider for 8254
  579. song_tick       DW      0h                              ;Song Tick
  580. song_counter    DW      0h                              ;Song Accumulator
  581. song_state      DB      0h                              ;Speaker On or Off
  582. song_addr    DW    music1,music1,music2,music3,music4
  583. music1        DW    2704,3,1,1805,3,1,1805,3,1,1805,3,1,1805,7,6,2027,3,1
  584.         DW    2275,3,1,2027,3,1,2275,3,1,2409,3,1,2704,13,5
  585.         DW    1352,3,1,1352,3,1,1352,3,1,1352,3,1,1352,7,6,1517,3,1
  586.         DW    3036,3,1,1517,3,1,1432,3,1,1704,3,1,1805,13,5
  587.         DW    1805,3,1,1352,3,1,1352,3,1,1517,3,1,1805,7,6,2027,3,1
  588.         DW    2275,3,1,2027,3,1,2275,3,1,2409,3,1,2704,7,6,3606,3,1
  589.         DW    3606,3,1,2275,3,1,2275,3,1,2409,3,1,2704,7,6,1805,3,1
  590.         DW    2027,3,1,2275,3,1,2409,3,1,3035,3,1,2704,10,3
  591.         DW    65535
  592. music2        DW    4047,3,1,3216,3,1,2704,3,1,2704,3,5,1352,1,3,1352,1,7
  593.         DW    1608,1,3,1608,1,7,4047,3,1,4047,3,1,3213,3,1,2704,3,1
  594.         DW    2704,3,5,1352,1,3,1352,1,7,1517,1,3
  595.         DW    1517,1,7,4296,3,1,4296,3,1,3606,3,1,2409,3,1,2409,3,5
  596.         DW    1204,1,3,1204,1,7,1517,1,3
  597.         DW    1517,1,7,4296,3,1,4296,3,1,3606,3,1,2409,3,1,2409,3,5
  598.         DW    1204,1,3,1204,1,7,1608,1,3,1608,1,7
  599.         DW    4047,3,1,3216,3,1,2704,3,1,2027,3,5
  600.         DW    1012,1,3,1012,1,7,1352,1,3,1352,1,7,4047,3,1
  601.         DW    4047,3,1,3216,3,1,2704,3,1,2027,3,5,1012,1,3
  602.         DW    1012,1,5,1204,1,3,1204,1,7,3606,1,1,3606,3,1
  603.         DW    3035,3,1,2409,1,3,2409,11,5,2867,3,1,2704,3,1,1608,12,4
  604.         DW    2027,3,1,3216,3,1,3216,6,2,3606,3,1,2409,6,2,2704,3,1,4047,3,3
  605.         DW    4047,1,1,4047,3,9,2704,1,3,3035,1,7,2704,1,3
  606.         DW    3035,1,7,2704,3,1,1608,12,4,1805,3,1,2704,1,3
  607.         DW    3216,1,7,2704,1,3,3216,1,7,2704,3,1
  608.         DW    1805,3,1,2704,3,1,2027,3,1,1805,3,1,1608,3,1,1352,6,2
  609.         DW    1517,3,1,1608,1,1,1608,1,1,1608,3,1,1805,1,3,2027,3,9
  610.         DW    65535
  611. music3        DW    1806,3,1,2705,27,1
  612.         DW    1,23,1,2705,2,1,2409,2,1,2275,2,1,2705,2,1
  613.         DW    1806,3,1,2705,3,1,2705,23,1
  614.         DW    1,23,1,2705,2,1,2409,2,1,2275,2,1,2705,2,1
  615.         DW    1806,15,1,2705,15,1
  616.         DW    1,20,1,2409,3,1,2275,3,1,2027,3,1
  617.         DW    1806,31,1
  618.         DW    1,31,1
  619.         DW    1352,7,1,2275,3,1,2275,19,1
  620.         DW    2275,7,1,1,3,1,1352,3,1,1518,3,1,1705,3,1,1806,3,1,1705,3,1
  621.         DW    1518,15,1,1518,3,1,1,11,1
  622.         DW    1,11,1,1518,3,1,1705,3,1,1806,3,1,2027,3,1,1806,3,1
  623.         DW    1705,7,1,1705,2,1,1806,2,1,1705,21,1
  624.         DW    1,11,1,1705,3,1,1806,3,1,2027,3,1,2275,3,1,2027,3,1
  625.         DW    1806,31,1
  626.         DW    1,31,1
  627.         DW    1352,7,1,1352,3,1,1,12,1
  628.         DW    1,7,1,1352,7,1,1518,7,1,1705,7,1
  629.         DW    1518,19,1,1518,3,1,1,12,1
  630.         DW    1,7,1,1518,7,1,1705,7,1,1806,7,1
  631.         DW    1705,19,1,1705,3,1,1,12,1
  632.         DW    1,19,1,2409,3,1,2409,3,1,2275,3,1,2027,3,1
  633.         DW    1806,31,1
  634.         DW    1806,3,1,2705,27,1
  635.         DW    1,23,1,2705,2,1,2409,2,1,2275,2,1,2705,2,1
  636.         DW    1806,3,1,2705,3,1,2705,23,1
  637.         DW    1,23,1,2705,2,1,2409,2,1,2275,2,1,2705,2,1
  638.         DW    1806,15,1,2705,15,1
  639.         DW    1,19,1,2409,3,1,2275,3,1,2027,3,1
  640.         DW    1806,31,1
  641.         DW    1,7,1,1806,31,1
  642.         DW    65535
  643. music4        DW    1352,3,1,1352,3,1,1204,3,1,1138,3,1,1013,3,1,1138,3,1,1204,3,1,1352,3,1
  644.         DW    1,3,1,1204,7,1,1518,3,1,1352,23,1
  645.         DW    1,3,1,1352,3,1,1204,3,1,1138,3,1
  646.         DW    1013,3,1,1138,3,1,1204,3,1,1352,3,1,1,3,1,1013,7,1,1138,3,1
  647.         DW    903,31,1
  648.         DW    1,3,1,852,2,1,852,5,1,903,3,1,903,3,1,1013,3,1,1013,2,1,2275,3,1
  649.         DW    1,3,1,1013,2,1,1138,2,1,1013,2,1,1138,3,1,903,7,1,1013,2,1,1138,3,1
  650.         DW    1352,63,1
  651.         DW    1,3,1,1352,3,1,676,3,1,759,3,1,676,3,1,759,2,1,903,9,1
  652.         DW    1,3,1,1013,3,1,1013,3,1,903,3,1,1013,3,1,1138,2,1,903,9,1
  653.         DW    1,3,1,852,3,1,852,3,1,852,2,1,759,2,1,852,7,1,903,3,1,1013,3,1
  654.         DW    903,15,1,676,15,1
  655.         DW    1,3,1,1352,3,1,676,3,1,759,3,1,676,3,1,759,2,1,903,9,1
  656.         DW    1,3,1,1013,3,1,1013,3,1,903,3,1,1013,3,1,1138,2,1,903,9,1
  657.         DW    1,3,1,852,3,1,852,3,1,852,2,1,759,2,1,852,7,1,903,3,1,1013,3,1
  658.         DW    903,31,1
  659.         DW    1,3,1,1013,3,1,1013,3,1,1138,3,1,1013,39,1
  660.         DW    1138,3,1,1204,3,1
  661.         DW    1352,63,1
  662.         DW    1,3,1,1352,3,1,1204,3,1,1138,3,1,1013,3,1,1138,3,1,1204,3,1,1352,3,1
  663.         DW    1,3,1,1204,7,1,1518,3,1,1352,31,1
  664.         DW    1,3,1,1352,3,1,1204,3,1,1138,3,1
  665.         DW    1013,3,1,1138,3,1,1204,3,1,1352,3,1,1,3,1,1013,3,1,1013,7,1
  666.         DW    1013,7,1,1138,7,1
  667.         DW    903,31,1
  668.         DW    1352,3,1,1352,3,1,1204,3,1,1138,3,1,1013,3,1,1138,3,1,1204,3,1,1352,3,1
  669.         DW    1,3,1,1204,7,1,1518,3,1,1352,23,1
  670.         DW    1,3,1,1352,3,1,1204,3,1,1138,3,1
  671.         DW    1013,3,1,1138,3,1,1204,3,1,1352,3,1,1,3,1,1013,7,1,1138,3,1
  672.         DW    903,31,1
  673.         DW    1,3,1,852,2,1,852,5,1,903,3,1,903,3,1,1013,3,1,1013,2,1,2275,3,1
  674.         DW    1,3,1,1013,2,1,1138,2,1,1013,2,1,1138,3,1,903,7,1,1013,2,1,1138,3,1
  675.         DW    1352,63,1
  676.         DW    65535
  677.  
  678.  
  679. ; The following is for GPSCR
  680. ;   0:main   1:int_1c 2:int9
  681. ;   3:int_B  4:int_C
  682. ;===================================
  683. begin_x     DB    5 DUP (?)
  684. begin_y     DB    5 DUP (?)
  685. end_x        DB    5 DUP (?)
  686. end_y        DB    5 DUP (?)
  687. gp_mode     DB    5 DUP (?)
  688.  
  689. ; The following is for running words
  690. ;===================================
  691. run_word_ptr    DW    0
  692. run_word_strptr DW    0
  693. run_word_count    DB    0
  694. run_word_str    DB    40 DUP (?)
  695. run_word    DB    'T',81,'h',81,'i',81,'s',81,' ',81,'P',81,'r',81,'o',81
  696.         DB    'g',81,'r',81,'a',81,'m',81,' ',81,'i',81,'s',81,' ',81
  697.         DB    'h',81,'o',81,'m',81,'e',81,'w',81,'o',81,'r',81,'k',81
  698.         DB    ' ',81,'o',81,'f',81,' ',81,'M',81,'i',81,'c',81,'r',81
  699.         DB    'o',81,'C',81,'o',81,'m',81,'p',81,'u',81,'t',81,'e',81
  700.         DB    'r',81,'.',81,' ',81,'T',81,'h',81,'e',81,' ',81,'t',81
  701.         DB    'i',81,'t',81,'l',81,'e',81,' ',81,'o',81,'f',81,' ',81
  702.         DB    'L',81,'A',81,'B',81,'4',81,' ',81,'i',81,'s',81,' ',81
  703.         DB    'A',81,'s',81,'y',81,'n',81,'c',81,'h',81,'r',81,'o',81
  704.         DB    'n',81,'o',81,'u',81,'s',81,'_',81,'S',81,'e',81,'r',81
  705.         DB    'i',81,'a',81,'l',81,'_',81,'C',81,'o',81,'m',81,'m',81
  706.         DB    'u',81,'n',81,'i',81,'c',81,'a',81,'t',81,'i',81,'o',81
  707.         DB    'n',81,'.',81,' ',81,'I',81,'t',81,' ',81,'i',81,'s',81
  708.         DB    ' ',81,'w',81,'r',81,'i',81,'t',81,'t',81,'e',81,'n',81
  709.         DB    ' ',81,'b',81,'y',81,' ',81,'Y',81,'u',81,'n',81,'g',81
  710.         DB    '-',81,'y',81,'i',81,' ',81,'L',81,'e',81,'e',81,',',81
  711.         DB    ' ',81,'N',81,'C',81,'U',81,' ',81,'M',81,'E',81,'.',81
  712.         DB    ' ',81,'[',81,'å',94,'ç',94,' ',94,'ê',94,'ë',94,' ',94
  713.         DB    ':',94,' ',94,'Ç',94,'ü',94,' ',94,'é',94,'â',94,' ',94
  714.         DB    'ä',94,'à',94,']',81,' ',81,'[',81,'è',95,'ï',95,' ',95
  715.         DB    'å',95,'ç',95,' ',95,':',95,' ',95,'ÿ',95,'Ö',95,' ',95
  716.         DB    'Ü',95,'¢',95,' ',95,'£',95,'¥',95,']',81,' ',81,'[',81
  717.         DB    'î',91,'ì',91,' ',91,'Ä',91,'Å',91,' ',91,'É',91,'æ',91
  718.         DB    ' ',91,'Æ',91,'ô',91,' ',91,'ö',91,'ò',91,' ',91,'û',91
  719.         DB    'ù',91,']',81,' ',81
  720.  
  721. ; The following is for int_1c
  722. ;===================================
  723. time_tmp    DB    2 DUP (?)
  724. time_str    DB    ?,31,?,31,':',31,?,31,?,31,':',31,?,31,?,31
  725. mydst_pmt    DB    '  ',13,10,'Your Workstation Number is : $'
  726. keymap          DB      ' ',7,'1234567890-=',6,'QWERTYUIOP[]',5,'ASDFGHJKL;'
  727.                 DB      39,'`\ZXCVBNM,./* ',1,2,3,4
  728.  
  729. ; The following is for send/rcv area
  730. ;===================================
  731. bar             DB      '\',13,'-',11,'/',14,'|',10     ;Bar Char.
  732. cls             DB      72 DUP (' ',14)                 ;Char.s for CLS
  733. askdst_mode     DB      0h                              ;If asking destination
  734. send_x          DB      2h                              ;X-coordernate of SEND
  735. send_y          DB      2h                              ;Y-coordernate of SEND
  736. rcv_x           DB      3h                              ;X-coordernate of RCV
  737. rcv_y           DB      0ah                             ;Y-coordernate of RCV
  738. char            DB      ?,14                            ;Char on Screen
  739. space           DB      ' ',14                          ;Space char.
  740. recording       DB      0h                              ;Recording Flag
  741. dst             DB      0h                              ;Destination
  742. mydst           DB      1h                              ;Your Station No.
  743. mychk           DB      0h                              ;Your CHK
  744. chk             DB      0h                              ;Send_CHK
  745. msg_ctr         DB      0h                              ;Send MSG Counter
  746. msg_ptr         DW      0h                              ;Send MSG Pointer
  747. msg_len         DB      0h                              ;Send MSG Length
  748. rcv_bar         DB      0h                              ;RCV Bar No.
  749. rcv_ptr         DW      0h                              ;RCV MSG Pointer
  750. rcv_len         DB      0h                              ;RCV MSG Length
  751. rcv_msg         DB      144 DUP (?)                     ;RCV MSG Buffer
  752. rcv_char        DB      ?,14                            ;RCV char. on Screen
  753. send_msg        DB      72 DUP (?)                      ;Send MSG Buffer
  754. send_bar        DB      0h                              ;SEND Bar No.
  755. send_self       DB      0h                              ;Send_Self Flag
  756. newc_state      DW      0h                              ;RCV ISR State
  757. newc_1st        DB      1h                              ;1st RCV ISR Flag
  758. dsp_ctr         DB      0h                              ;DSPRCV Counter
  759. sleep           DB      0h                              ;Sleep Flag
  760. sleep_ctr       DW      0h                              ;Sleep Counter
  761.  
  762. ;-------------------------------------------------------------------------------
  763. ;  NEW_B : New 0Bh ISR (COM2:Sender)
  764. ;-------------------------------------------------------------------------------
  765. NEW_B           PROC    NEAR
  766.  
  767.                 cli
  768.                 push    ax
  769.                 push    bx
  770.                 push    cx
  771.                 push    dx
  772.                 push    ds
  773.                 push    si
  774.  
  775.                 mov     cx, @code                       ;Show rotating bar
  776.                 mov     ds, cx
  777.                 xor     bh, bh
  778.                 mov     bl, CS:SEND_BAR
  779.                 shl     bl, 1h
  780.                 lea     si, CS:BAR[bx]
  781.                 mov     ax, 0601h
  782.                 mov     dx, ax
  783.                 mov     ch, PUT_MODE
  784.                 mov     cl, 3h
  785.                 call    GPSCR
  786.                 inc     CS:SEND_BAR
  787.                 cmp     CS:SEND_BAR, 4h
  788.                 jl      newb_again
  789.                 mov     CS:SEND_BAR, 0h
  790.  
  791. newb_again:     mov     dx, 2fdh                        ;Test if SEND_PORT
  792.                 in      al, dx                          ;  is empty !
  793.                 test    al, 01100000b
  794.                 jz      newb_again
  795.  
  796.                 mov     al, 20h                         ;Send EOI
  797.                 out     20h, al
  798.                 pop     si
  799.                 pop     ds
  800.                 pop     dx
  801.                 pop     cx
  802.                 pop     bx
  803.                 pop     ax
  804.                 sti
  805.         iret
  806.  
  807. NEW_B        ENDP
  808.  
  809. ;-------------------------------------------------------------------------------
  810. ;  NEW_C : New 0Ch ISR (COM1:Receiver)
  811. ;-------------------------------------------------------------------------------
  812. NEW_C           PROC    NEAR
  813.  
  814.                 cli
  815.                 push    ax
  816.                 push    bx
  817.                 push    cx
  818.                 push    dx
  819.                 push    ds
  820.                 push    si
  821.  
  822.                 mov     cx, @code                       ;Show rotating bar
  823.                 mov     ds, cx
  824.                 xor     bh, bh
  825.                 mov     bl, CS:RCV_BAR
  826.                 shl     bl, 1h
  827.                 lea     si, CS:BAR[bx]
  828.         mov    ax, 0609h
  829.         mov    dx, ax
  830.         mov    ch, PUT_MODE
  831.         mov    cl, 4h
  832.                 call    GPSCR
  833.         inc    CS:RCV_BAR
  834.         cmp    CS:RCV_BAR, 4h
  835.         jl    newc_begin
  836.                 mov     CS:RCV_BAR, 0h
  837.  
  838. newc_begin:     cmp     CS:NEWC_1ST, YES                ;If 1st startup
  839.                 jne     newc_begin1
  840.                 mov     CS:NEWC_1ST, NO
  841.                 mov     CS:NEWC_STATE, OFFSET cs:state_0r
  842.                 mov     dx, RCV_PORT
  843.                 in      al, dx
  844.                 mov     al, ETX
  845.                 jmp     newc_exit
  846. newc_begin1:    mov     dx, RCV_PORT
  847.                 in      al, dx
  848.                 jmp     WORD PTR CS:NEWC_STATE
  849.  
  850. state_0r:       cmp     al, ETX
  851.                 je      st_0r1
  852.                 cmp     al, SOH
  853.                 jne     newc_exit
  854.                 mov     CS:NEWC_STATE, OFFSET cs:state_1d
  855.         jmp    newc_exit
  856. st_0r1:         cmp     CS:DST, NULL
  857.         je    newc_exit
  858.                 mov     al, SOH
  859.         mov    CS:NEWC_STATE, OFFSET cs:state_0m
  860.         jmp    newc_exit
  861.  
  862. state_1d:       cmp     al, CS:MYDST
  863.                 je      st_1d1
  864.         mov    CS:NEWC_STATE, OFFSET cs:state_0r
  865.         jmp    newc_exit
  866. st_1d1:         mov     CS:RCV_PTR, OFFSET CS:RCV_MSG
  867.         mov    CS:NEWC_STATE, OFFSET cs:state_2d
  868.         jmp    newc_exit
  869.  
  870. state_2d:       cmp     al, DLE
  871.                 je      st_2d1
  872.                 mov     al, CAN
  873.         mov    CS:NEWC_STATE, OFFSET cs:state_0r
  874.         jmp    newc_exit
  875. st_2d1:         mov     CS:NEWC_STATE, OFFSET cs:state_3d
  876.         jmp    newc_exit
  877.  
  878. state_3d:       cmp     al, 144
  879.                 jbe     st_3d1
  880.                 mov     al, CAN
  881.         mov    CS:NEWC_STATE, OFFSET cs:state_0r
  882.         jmp    newc_exit
  883. st_3d1:         mov     CS:RCV_LEN, al
  884.                 mov     CS:MSG_CTR, al
  885.                 mov     cl, CS:MYDST
  886.                 mov     CS:MYCHK, cl
  887.                 add     CS:MYCHK, al
  888.                 add     CS:MYCHK, DLE
  889. st_3d3:         cmp     CS:MSG_CTR, 0h
  890.                 je      st_3d2
  891.         mov    CS:NEWC_STATE, OFFSET cs:state_4d
  892.         jmp    newc_exit
  893. st_3d2:         mov     CS:NEWC_STATE, OFFSET cs:state_5d
  894.         jmp    newc_exit
  895.  
  896. state_4d:       cmp     al, CAN
  897.                 je      st_4d1
  898.         dec    CS:MSG_CTR
  899.                 add     CS:MYCHK, al
  900.                 mov     si, CS:RCV_PTR
  901.                 mov     [si], al
  902.         inc    CS:RCV_PTR
  903.                 jmp     st_3d3
  904. st_4d1:         mov     CS:NEWC_STATE, OFFSET cs:state_0r
  905.         jmp    newc_exit
  906.  
  907. state_5d:       cmp     al, ETB
  908.                 je      st_5d1
  909.                 mov     al, CAN
  910.         mov    CS:NEWC_STATE, OFFSET cs:state_0r
  911.         jmp    newc_exit
  912. st_5d1:         mov     CS:NEWC_STATE, OFFSET cs:state_6d
  913.         jmp    newc_exit
  914.  
  915. state_6d:       cmp     al, DLE
  916.                 je      st_6d1
  917.                 mov     al, CAN
  918.         mov    CS:NEWC_STATE, OFFSET cs:state_0r
  919.         jmp    newc_exit
  920. st_6d1:         mov     CS:NEWC_STATE, OFFSET cs:state_7d
  921.         jmp    newc_exit
  922.  
  923. state_7d:       cmp     al, CS:MYCHK
  924.                 je      st_7d1
  925.                 mov     al, NAK
  926.         mov    CS:NEWC_STATE, OFFSET cs:state_0r
  927.         jmp    newc_exit
  928. st_7d1:         call    DSPRCV
  929.                 mov     al, ACK
  930.         mov    CS:NEWC_STATE, OFFSET cs:state_0r
  931.                 jmp     newc_exit
  932.  
  933. state_0m:       cmp     al, SOH
  934.                 je      st_0m1
  935.                 mov     al, CAN
  936.         mov    CS:NEWC_STATE, OFFSET cs:state_em
  937.         jmp    newc_exit
  938. st_0m1:         mov     CS:MSG_PTR, OFFSET CS:SEND_MSG
  939.                 mov     al, CS:DST
  940.         mov    CS:NEWC_STATE, OFFSET cs:state_1m
  941.         jmp    newc_exit
  942.  
  943. state_em:       cmp     al, CAN
  944.                 je      st_em1
  945.                 mov     al, CAN
  946.         jmp    newc_exit
  947. st_em1:         mov     al, SOH
  948.         mov    CS:NEWC_STATE, OFFSET cs:state_0m
  949.         jmp    newc_exit
  950.  
  951. state_1m:       cmp     al, CS:DST
  952.                 je      st_1m1
  953.                 mov     al, CAN
  954.         mov    CS:NEWC_STATE, OFFSET cs:state_em
  955.         jmp    newc_exit
  956. st_1m1:         cmp     al, CS:MYDST
  957.                 jne     st_1m2
  958.         mov    CS:SEND_SELF, YES
  959.                 mov     CS:RCV_PTR, OFFSET CS:RCV_MSG
  960. st_1m2:         mov     al, DLE
  961.         mov    CS:NEWC_STATE, OFFSET cs:state_2m
  962.         jmp    newc_exit
  963.  
  964. state_2m:       cmp     al, DLE
  965.                 je      st_2m1
  966.                 mov     al, CAN
  967.         mov    CS:NEWC_STATE, OFFSET cs:state_em
  968.         jmp    newc_exit
  969. st_2m1:         mov     al, CS:MSG_LEN
  970.         mov    CS:NEWC_STATE, OFFSET cs:state_3m
  971.         jmp    newc_exit
  972.  
  973. state_3m:       cmp     al, CS:MSG_LEN
  974.                 je      st_3m1
  975.                 mov     al, CAN
  976.         mov    CS:NEWC_STATE, OFFSET cs:state_em
  977.         jmp    newc_exit
  978. st_3m1:         mov     CS:MSG_CTR, al
  979.         cmp    CS:SEND_SELF, YES
  980.                 je      st_3m2
  981.                 mov     cl, CS:DST
  982.                 mov     CS:CHK, cl
  983.                 add     CS:CHK, al
  984.                 add     CS:CHK, DLE
  985.                 je      st_3m3
  986. st_3m2:         mov     CS:RCV_LEN, al
  987.         mov    cl, CS:DST
  988.         mov    CS:MYCHK, cl
  989.                 add     CS:MYCHK, al
  990.                 add     CS:MYCHK, DLE
  991. st_3m3:         cmp     CS:MSG_CTR, 0h
  992.                 je      st_3m4
  993.                 mov     si, CS:MSG_PTR
  994.                 mov     al, BYTE PTR [si]
  995.                 cmp     al, '*'
  996.                 jne     st_3m5
  997.                 add     CS:CHK, 5h
  998.                 add     CS:MYCHK, 5h
  999.                 mov     cl, '/'
  1000.                 mov     [si], cl
  1001. st_3m5:         mov     CS:NEWC_STATE, OFFSET cs:state_4m
  1002.         jmp    newc_exit
  1003. st_3m4:         mov     al, ETB
  1004.         mov    CS:NEWC_STATE, OFFSET cs:state_5m
  1005.         jmp    newc_exit
  1006.  
  1007. state_4m:       mov     si, CS:MSG_PTR
  1008.                 cmp     al, [si]
  1009.                 je      st_4m1
  1010.                 mov     al, CAN
  1011.         mov    CS:NEWC_STATE, OFFSET cs:state_em
  1012.         jmp    newc_exit
  1013. st_4m1:         dec     CS:MSG_CTR
  1014.         cmp    CS:SEND_SELF, YES
  1015.                 je      st_4m2
  1016.                 add     CS:CHK, al
  1017.                 inc     CS:MSG_PTR
  1018.                 jmp     st_3m3
  1019. st_4m2:         add     CS:MYCHK, al
  1020.                 mov     si, CS:RCV_PTR
  1021.                 mov     [si], al
  1022.         inc    CS:RCV_PTR
  1023.         inc    CS:MSG_PTR
  1024.                 jmp     st_3m3
  1025.  
  1026. state_5m:       cmp     al, ETB
  1027.                 je      st_5m1
  1028.                 mov     al, CAN
  1029.         mov    CS:NEWC_STATE, OFFSET cs:state_em
  1030.         jmp    newc_exit
  1031. st_5m1:         mov     al, DLE
  1032.         mov    CS:NEWC_STATE, OFFSET cs:state_6m
  1033.         jmp    newc_exit
  1034.  
  1035. state_6m:       cmp     al, DLE
  1036.                 je      st_6m1
  1037.                 mov     al, CAN
  1038.         mov    CS:NEWC_STATE, OFFSET cs:state_em
  1039.         jmp    newc_exit
  1040. st_6m1:         mov     al, CS:CHK
  1041.                 cmp     CS:SEND_SELF, YES
  1042.                 jne     st_6m2
  1043.                 mov     al, CS:MYCHK
  1044. st_6m2:         mov     CS:NEWC_STATE, OFFSET cs:state_7m
  1045.         jmp    newc_exit
  1046.  
  1047. state_7m:       cmp     CS:SEND_SELF, YES
  1048.                 je      st_7m1
  1049.                 cmp     al, ACK
  1050.                 je      st_7m2
  1051.                 cmp     al, CS:CHK
  1052.                 je      st_7m4
  1053.                 mov     al, CAN
  1054.         mov    CS:NEWC_STATE, OFFSET cs:state_em
  1055.         jmp    newc_exit
  1056. st_7m2:         mov     CS:DST, NULL
  1057.                 mov     al, ETX
  1058.                 mov     CS:NEWC_STATE, OFFSET cs:state_0r
  1059.         jmp    newc_exit
  1060. st_7m1:         cmp     al, CS:MYCHK
  1061.                 je      st_7m3
  1062.                 mov     al, CAN
  1063.         mov    CS:NEWC_STATE, OFFSET cs:state_em
  1064.         jmp    newc_exit
  1065. st_7m3:         call    DSPRCV
  1066.         mov    CS:DST, NULL
  1067.         mov    CS:SEND_SELF, NO
  1068.                 mov     al, ETX
  1069.         mov    CS:NEWC_STATE, OFFSET cs:state_0r
  1070.         jmp    newc_exit
  1071. st_7m4:         mov     ah, 2h
  1072.                 mov     dl, 7h
  1073.                 int     21h
  1074.                 jmp     st_7m2
  1075.  
  1076. newc_exit:      mov     dx, SEND_PORT                   ;Send data to COM2
  1077.                 out     dx, al
  1078.                 mov     al, 20h                         ;Send EOI
  1079.                 out     20h, al
  1080.                 pop     si
  1081.                 pop     ds
  1082.                 pop     dx
  1083.                 pop     cx
  1084.                 pop     bx
  1085.                 pop     ax
  1086.                 sti
  1087.         iret
  1088.  
  1089. NEW_C        ENDP
  1090.  
  1091. ;-------------------------------------------------------------------------------
  1092. ;  DSPRCV : Display receive message
  1093. ;-------------------------------------------------------------------------------
  1094. DSPRCV        PROC    NEAR
  1095.  
  1096.         push    ax
  1097.         push    bx
  1098.         push    cx
  1099.         push    dx
  1100.         push    ds
  1101.         push    si
  1102.  
  1103.                 mov     CS:SLEEP, NO
  1104.                 mov     CS:SLEEP_CTR, 0h
  1105.  
  1106.                 xor     bx, bx
  1107.                 mov     CS:DSP_CTR, 0h
  1108. dsp_cls:        mov     cx, @code                       ;Clear Current Line
  1109.                 mov     ds, cx
  1110.                 mov     si, OFFSET CS:CLS
  1111.         mov    ah, CS:RCV_X
  1112.         mov    al, CS:RCV_Y
  1113.         mov    dx, ax
  1114.         add    dx, 4700h
  1115.         mov    ch, PUT_MODE
  1116.                 mov     cl, 4h
  1117.         call    GPSCR
  1118.  
  1119. dsp_begin:      mov     cl, CS:RCV_MSG[bx]              ;Display Message
  1120.                 mov     CS:RCV_CHAR, cl
  1121.                 mov     cx, @code
  1122.                 mov     ds, cx
  1123.                 mov     si, OFFSET CS:RCV_CHAR
  1124.         mov    al, CS:RCV_Y
  1125.                 mov     ah, CS:RCV_X
  1126.         mov    dx, ax
  1127.         mov    ch, PUT_MODE
  1128.                 mov     cl, 4h
  1129.         call    GPSCR
  1130.  
  1131.         inc    bx
  1132.                 cmp     bl, CS:RCV_LEN
  1133.                 je      dsp_exit
  1134.                 inc     CS:RCV_X
  1135.                 inc     CS:DSP_CTR
  1136.                 cmp     CS:DSP_CTR, 72
  1137.                 jl      dsp_begin
  1138.                 mov     CS:DSP_CTR, 0h
  1139.                 mov     CS:RCV_X, 3h
  1140.                 inc     CS:RCV_Y
  1141.                 cmp     CS:RCV_Y, 17
  1142.                 jl      dsp_cls
  1143.                 mov     CS:RCV_Y, 0ah
  1144.                 jmp     dsp_cls
  1145.  
  1146. dsp_exit:       mov     CS:RCV_X, 3h
  1147.                 inc     CS:RCV_Y
  1148.                 cmp     CS:RCV_Y, 17
  1149.                 jl      dsp_exit1
  1150.                 mov     CS:RCV_Y, 0ah
  1151. dsp_exit1:      pop     si
  1152.         pop    ds
  1153.         pop    dx
  1154.         pop    cx
  1155.         pop    bx
  1156.         pop    ax
  1157.         ret
  1158.  
  1159. DSPRCV        ENDP
  1160.  
  1161. ;------------------------------------------------------------------------------
  1162. ;  NEW_9 : New 9h ISR
  1163. ;------------------------------------------------------------------------------
  1164. NEW_9        PROC    NEAR
  1165.  
  1166.         push    ax
  1167.         push    bx
  1168.         push    cx
  1169.         push    dx
  1170.         push    ds
  1171.         push    si
  1172.  
  1173.                 sti
  1174.                 mov     CS:SLEEP, NO
  1175.                 mov     CS:SLEEP_CTR, 0h
  1176.                 mov     al, 20h                         ;Send EOI
  1177.                 out     20h, al
  1178.                 in      al, 60h                         ;Get KB Char.
  1179.                 test    al, 80h
  1180.                 jnz     new9_exit
  1181.  
  1182.                 push    cs
  1183.                 pop     ds
  1184.                 lea     bx, CS:KEYMAP
  1185.                 xlatb
  1186.                 cmp     al, NOTHING
  1187.                 je      new9_exit
  1188.  
  1189.                 cmp     CS:ASKDST_MODE, YES
  1190.         jne    new9_case
  1191.                 cmp     al, '0'
  1192.         jl    new9_exit
  1193.                 cmp     al, '7'
  1194.         jg    new9_exit
  1195.         mov    CS:DST, al
  1196.                 mov     CS:ASKDST_MODE, NO
  1197.                 call    ASKDST
  1198.         jmp    new9_exit
  1199.  
  1200. new9_case:      cmp     al, F2
  1201.         je    new9_1
  1202.         cmp    al, ESCAPE
  1203.         je    new9_2
  1204.         cmp    al, RETURN
  1205.         je    new9_3
  1206.         cmp    al, F1
  1207.         je    new9_4
  1208.         cmp    al, F3
  1209.         je    new9_5
  1210.         cmp    al, F4
  1211.         je    new9_6
  1212.         cmp    al, BACK
  1213.         jne    new9_def
  1214.  
  1215. new9_7:     cmp    CS:RECORDING, YES        ;  BACKSPACE
  1216.                 jne     back1                           ;=============
  1217.                 cmp     CS:MSG_LEN, 0h
  1218.                 je      back1
  1219.                 dec     CS:MSG_LEN
  1220. back1:          cmp     CS:SEND_X, 3h
  1221.         jl    new9_exit
  1222.                 mov     cx, @code                       ;Clear old char.
  1223.                 mov     ds, cx                          ;  ⌠ BEGIN
  1224.                 mov     si, OFFSET CS:SPACE             ;  │
  1225.         mov    ah, CS:SEND_X            ;  │
  1226.         mov    al, CS:SEND_Y            ;  │
  1227.         mov    dx, ax                ;  │
  1228.         push    dx                ;  │
  1229.         mov    ch, PUT_MODE            ;  │
  1230.         mov    cl, 2h                ;  │
  1231.         call    GPSCR                ;  ⌡ END
  1232.         pop    dx                ;Set new cursor
  1233.         xchg    dl, dh                ;  ⌠ BEGIN
  1234.         mov    bh, 0h                ;  │
  1235.         mov    ah, 2h                ;  │
  1236.         int    10h                ;  │
  1237.         dec    CS:SEND_X            ;  ⌡ END
  1238.         jmp    new9_exit
  1239.  
  1240. new9_1:     inc    CS:SONG_PTR            ;  MUSIC SWITCH
  1241.         cmp    CS:SONG_PTR, 5h         ;================
  1242.                 jl      song1                           ;Show current song No.
  1243.                 mov     cx, 0                           ;  ⌠ BEGIN
  1244.                 mov     CS:SONG_PTR, cx                 ;  │
  1245. song1:          mov     bx, CS:SONG_PTR                 ;  │
  1246.         mov    dl, CS:SONG_INDEX[bx]        ;  │
  1247.         mov    CS:SONG_SIGN, dl        ;  │
  1248.                 mov     cx, @code                       ;  │
  1249.                 mov     ds, cx                          ;  │
  1250.                 mov     si, OFFSET CS:SONG_SIGN         ;  │
  1251.         mov    ax, 1418h            ;  │
  1252.         mov    dx, 1418h            ;  │
  1253.         mov    ch, PUT_MODE            ;  │
  1254.         mov    cl, 2h                ;  │
  1255.         call    GPSCR                ;  ⌡ END
  1256.         cmp    CS:SONG_PTR, 0h         ;(no song)? turn_off:a4
  1257.                 jne     song2                           ;Turn off spacker
  1258.                 mov     CS:SONG_FLAG, NO                ;  ⌠ BEGIN
  1259.         mov    CS:SONG_COUNTER, 0h        ;  │
  1260.         in    al, SOUND_SWITCH        ;  │
  1261.         and    al, 11111100b            ;  │
  1262.         out    SOUND_SWITCH, al        ;  │
  1263.         jmp    new9_exit            ;  ⌡ END
  1264. song2:          mov     CS:SONG_FLAG, NO                ;LABEL: song2
  1265.         in    al, SOUND_SWITCH        ;Turn on the speaker &
  1266.         and    al, 11111100b            ;Set up new song handle
  1267.         out    SOUND_SWITCH, al        ;  ⌠ BEGIN
  1268.         mov    al, 0b6h            ;  │
  1269.         out    SOUND_CONTROL, al        ;  │
  1270.         mov    ax, CS:SONG_PTR         ;  │
  1271.                 mov     bx, ax                          ;  │
  1272.                 shl     bx, 1                           ;  │
  1273.                 mov     cx, CS:SONG_ADDR[bx]            ;  │
  1274.                 mov     CS:SONG_POINTER, cx             ;  │
  1275.         mov    si, CS:SONG_POINTER        ;  │
  1276.                 mov     cx, CS:[si]                     ;  │
  1277.                 mov     CS:SONG_FREQUENCY, cx           ;  │
  1278.         add    CS:SONG_POINTER, 2h        ;  │
  1279.         mov    si, CS:SONG_POINTER        ;  │
  1280.                 mov     cx, CS:[si]                     ;  │
  1281.                 mov     CS:SONG_TICK, cx                ;  │
  1282.                 mov     ax, CS:SONG_FREQUENCY           ;  │
  1283.         out    SOUND_PORT, al            ;  │
  1284.         mov    al, ah                ;  │
  1285.         out    SOUND_PORT, al            ;  │
  1286.         in    al, SOUND_SWITCH        ;  │
  1287.         or    al, 3h                ;  │
  1288.         out    SOUND_SWITCH, al        ;  │
  1289.         mov    CS:SONG_COUNTER, 0h        ;  │
  1290.         mov    CS:SONG_STATE, YES        ;  │
  1291.         mov    CS:SONG_FLAG, YES        ;  ⌡ END
  1292.         jmp    new9_exit
  1293.  
  1294. new9_2:         cli                                     ;  ESCAPE
  1295.                 call    SHUTDOWN                        ;==========
  1296.                 pop     si                              ;Pop register &
  1297.                 pop     ds                              ;  ⌠ BEGIN
  1298.                 pop     dx                              ;  │
  1299.                 pop     cx                              ;  │
  1300.                 pop     bx                              ;  │
  1301.                 pop     ax                              ;  ⌡ END
  1302.                 mov     ah, 4ch                         ;Exit program
  1303.                 int     21h                             ;
  1304.  
  1305. new9_3:         mov     CS:SEND_X, 2h                   ;  RETURN
  1306.                 inc     CS:SEND_Y                       ;==========
  1307.                 cmp     CS:SEND_Y, 8h                   ;Set new cursor
  1308.                 jle     ent1                            ;  ⌠ BEGIN
  1309.                 mov     CS:SEND_Y, 2h                   ;  │
  1310. ent1:           mov     dl, CS:SEND_X                   ;  │
  1311.         mov    dh, CS:SEND_Y            ;  │
  1312.         add    dx, 1h                ;  │
  1313.         push    dx                ;  │
  1314.         mov    bh, 0h                ;  │
  1315.         mov    ah, 2h                ;  │
  1316.         int    10h                ;  ⌡ END
  1317.                 mov     cx, @code                       ;Clear Next Line
  1318.                 mov     ds, cx                          ;  ⌠ BEGIN
  1319.                 mov     si, OFFSET CS:CLS               ;  │
  1320.         pop    ax                ;  │
  1321.         xchg    al, ah                ;  │
  1322.         mov    dx, ax                ;  │
  1323.         add    dx, 4700h            ;  │
  1324.         mov    ch, PUT_MODE            ;  │
  1325.         mov    cl, 2h                ;  │
  1326.         call    GPSCR                ;  ⌡ END
  1327.         cmp    CS:RECORDING, YES        ;(record send_msg)? /
  1328.         jne    new9_exit            ;  end_record:new9_exit
  1329.         mov    CS:RECORDING, NO        ;End recording
  1330.         mov    CS:CHAR+1, 14            ;  ⌠ BEGIN
  1331.                 mov     CS:ASKDST_MODE, YES             ;  │
  1332.                 call    ASKDST                          ;  ⌡ END
  1333.         jmp    new9_exit
  1334.  
  1335. new9_4:     cmp    CS:RECORDING, YES        ;  F1
  1336.         je    new9_exit            ;======
  1337.                 cmp     CS:DST, NULL
  1338.                 jne     new9_exit
  1339.         mov    CS:RECORDING, YES
  1340.                 mov     CS:MSG_LEN, 0h
  1341.         mov    CS:CHAR+1, 10
  1342.         mov    CS:SEND_X, 2h
  1343.         inc    CS:SEND_Y
  1344.         cmp    CS:SEND_Y, 8h
  1345.                 jle     f11
  1346.         mov    CS:SEND_Y, 2h
  1347. f11:            mov     dl, CS:SEND_X
  1348.         mov    dh, CS:SEND_Y
  1349.         add    dx, 1h
  1350.         push    dx
  1351.         mov    bh, 0h
  1352.         mov    ah, 2h
  1353.         int    10h
  1354.                 mov     cx, @code
  1355.                 mov     ds, cx
  1356.                 mov     si, OFFSET CS:CLS
  1357.         pop    ax
  1358.         xchg    al, ah
  1359.         mov    dx, ax
  1360.         add    dx, 4700h
  1361.         mov    ch, PUT_MODE
  1362.         mov    cl, 2h
  1363.         call    GPSCR
  1364.         jmp    new9_exit
  1365.  
  1366. new9_5:         cmp     CS:RECORDING, YES               ;  F3
  1367.                 je      new9_exit                       ;======
  1368.         mov    dx, 0202h
  1369.         mov    CS:SEND_X, dl
  1370.         mov    CS:SEND_Y, dh
  1371.         add    dx, 1h
  1372.         mov    bh, 0h
  1373.         mov    ah, 2h
  1374.         int    10h
  1375.         mov    bx, 0h
  1376. f31:            cmp     bx, 7h
  1377.         je    new9_exit
  1378.                 mov     cx, @code
  1379.                 mov     ds, cx
  1380.                 mov     si, OFFSET CS:CLS
  1381.         mov    ax, 0302h
  1382.         add    ax, bx
  1383.         mov    dx, ax
  1384.         add    dx, 4700h
  1385.         mov    ch, PUT_MODE
  1386.         mov    cl, 2h
  1387.         call    GPSCR
  1388.         inc    bx
  1389.                 loop    f31
  1390.  
  1391. new9_6:         mov     bx, 0h                          ;  F4
  1392.                 mov     CS:RCV_X, 3h                    ;======
  1393.                 mov     CS:RCV_Y, 0ah
  1394. f41:            cmp     bx, 7h
  1395.         je    new9_exit
  1396.                 mov     cx, @code
  1397.                 mov     ds, cx
  1398.                 mov     si, OFFSET CS:CLS
  1399.         mov    ax, 030ah
  1400.         add    ax, bx
  1401.         mov    dx, ax
  1402.         add    dx, 4700h
  1403.         mov    ch, PUT_MODE
  1404.         mov    cl, 2h
  1405.         call    GPSCR
  1406.         inc    bx
  1407.                 loop    f41
  1408.  
  1409. new9_def:       cmp     CS:RECORDING, YES               ;  Default Keyin
  1410.                 jne     def1                            ;=================
  1411.                 cmp     CS:MSG_LEN, 72
  1412.                 je      def4
  1413.                 inc     CS:MSG_LEN
  1414. def4:           xor     bh, bh
  1415.         mov    bl, CS:MSG_LEN
  1416.                 dec     bx
  1417.         mov    CS:SEND_MSG[bx], al
  1418. def1:           inc     CS:SEND_X
  1419.         cmp    CS:SEND_X, 74
  1420.                 jle     def2
  1421.         cmp    CS:RECORDING, YES
  1422.                 je      def3
  1423.                 mov     CS:SEND_X, 3h
  1424.         inc    CS:SEND_Y
  1425.         cmp    CS:SEND_Y, 8h
  1426.                 jle     def2
  1427.                 mov     CS:SEND_Y, 2h
  1428.                 jmp     def2
  1429. def3:           mov     CS:SEND_X, 74
  1430. def2:           mov     CS:CHAR, al
  1431.                 mov     cx, @code
  1432.                 mov     ds, cx
  1433.                 mov     si, OFFSET CS:CHAR
  1434.         mov    ch, PUT_MODE
  1435.         mov    cl, 2h
  1436.         mov    ah, CS:SEND_X
  1437.         mov    al, CS:SEND_Y
  1438.         mov    dx, ax
  1439.         call    GPSCR
  1440.         mov    dl, CS:SEND_X
  1441.         mov    dh, CS:SEND_Y
  1442.         add    dx, 1h
  1443.         mov    bh, 0h
  1444.         mov    ah, 2h
  1445.         int    10h
  1446.         jmp    new9_exit
  1447.  
  1448. new9_exit:      pop     si
  1449.                 pop     ds
  1450.                 pop     dx
  1451.                 pop     cx
  1452.                 pop     bx
  1453.                 pop     ax
  1454.                 iret
  1455.  
  1456. NEW_9        ENDP
  1457.  
  1458. ;-------------------------------------------------------------------------------
  1459. ;  ASKDST : Ask for message destination
  1460. ;-------------------------------------------------------------------------------
  1461. ASKDST          PROC    NEAR
  1462.  
  1463.         push    cx
  1464.         push    es
  1465.         push    di
  1466.         push    ax
  1467.  
  1468.                 mov     cx, CS:VIDEO_BASE
  1469.                 mov     es, cx
  1470.                 mov     di, 3269
  1471.         mov    cx, 11
  1472.                 cmp     CS:ASKDST_MODE, YES
  1473.                 jne     askdst_loop2
  1474.  
  1475. askdst_loop1:   mov     al, 159                         ;Prompt for DST
  1476.         stosb                    ;  ⌠ BEGIN
  1477.         inc    di                ;  │
  1478.                 loop    askdst_loop1                    ;  │
  1479.         mov    al, 31                ;  │
  1480.                 mov     di, 3438                        ;  │
  1481.         mov    al, ' '                         ;  │
  1482.         stosb                    ;  ⌡ END
  1483.                 jmp     askdst_exit
  1484.  
  1485. askdst_loop2:   mov     al, 31                          ;Restore prompt
  1486.         stosb                    ;  ⌠ BEGIN
  1487.         inc    di                ;  │
  1488.                 loop    askdst_loop2                    ;  │
  1489.                 mov     di, 3438                        ;  │
  1490.         pop    ax                ;  │
  1491.         push    ax                ;  │
  1492.         stosb                    ;  ⌡ END
  1493.  
  1494. askdst_exit:    pop     ax
  1495.         pop    di
  1496.         pop    es
  1497.         pop    cx
  1498.         ret
  1499.  
  1500. ASKDST          ENDP
  1501.  
  1502. ;------------------------------------------------------------------------------
  1503. ;  NEW_1C : New 1ch ISR
  1504. ;------------------------------------------------------------------------------
  1505. NEW_1C        PROC    NEAR
  1506.  
  1507.                 sti
  1508.                 push    ax
  1509.  
  1510.                 call    RUNNING
  1511.                 call    TIME
  1512.                 call    MUSIC
  1513.  
  1514.                 inc     CS:SLEEP_CTR
  1515.                 cmp     CS:SLEEP, YES
  1516.                 je      new1c_sleep
  1517.                 cmp     CS:SLEEP_CTR, 364
  1518.                 jne     new1c_nosleep
  1519.                 mov     CS:SLEEP, YES
  1520.                 mov     CS:SLEEP_CTR, 0h
  1521. new1c_sleep:    mov     al, 1h
  1522.                 mov     ah, 5h
  1523.                 int     10h
  1524.                 jmp     new1c_exit
  1525. new1c_nosleep:  mov     al, 0h
  1526.                 mov     ah, 5h
  1527.                 int     10h
  1528.                 jmp     new1c_exit
  1529.  
  1530.  
  1531. new1c_exit:     pop     ax
  1532.                 iret
  1533.  
  1534. NEW_1C        ENDP
  1535.  
  1536. ;------------------------------------------------------------------------------
  1537. ;  MUSIC : Manage music
  1538. ;------------------------------------------------------------------------------
  1539. MUSIC        PROC    NEAR
  1540.  
  1541.                 pushf
  1542.         push    ax
  1543.         push    si
  1544.  
  1545.         cmp    CS:SONG_FLAG, YES
  1546.         jne    music_exit
  1547.         mov    ax, CS:SONG_TICK
  1548.         cmp    CS:SONG_COUNTER, ax
  1549.                 je      mu1
  1550.         inc    CS:SONG_COUNTER
  1551.         jmp    music_exit
  1552. mu1:            mov     CS:SONG_COUNTER, 0h
  1553.         cmp    CS:SONG_STATE, YES
  1554.         jne    speakeron
  1555.         mov    CS:SONG_STATE, NO
  1556.         add    CS:SONG_POINTER, 2h
  1557.         mov    si, CS:SONG_POINTER
  1558.         mov    ax, CS:[si]
  1559.         mov    CS:SONG_TICK, ax
  1560.         in    al, SOUND_SWITCH
  1561.         and    al, 11111100b
  1562.         out    SOUND_SWITCH, al
  1563.         jmp    music_exit
  1564. speakeron:    mov    CS:SONG_STATE, YES
  1565.         add    CS:SONG_POINTER, 2h
  1566.         mov    si, CS:SONG_POINTER
  1567.         mov    ax, CS:[si]
  1568.         mov    CS:SONG_FREQUENCY, ax
  1569.         cmp    CS:SONG_FREQUENCY, 65535
  1570.         jne    continue
  1571.         in    al, SOUND_SWITCH
  1572.         and    al, 11111100b
  1573.         out    SOUND_SWITCH, al
  1574.         mov    CS:SONG_FLAG, NO
  1575.         jne    music_exit
  1576. continue:    add    CS:SONG_POINTER, 2h
  1577.         mov    si, CS:SONG_POINTER
  1578.         mov    ax, CS:[si]
  1579.         mov    CS:SONG_TICK, ax
  1580.         mov    ax, CS:SONG_FREQUENCY
  1581.         out    SOUND_PORT, al
  1582.         mov    al, ah
  1583.         out    SOUND_PORT, al
  1584.         in    al, SOUND_SWITCH
  1585.         or    al, 3h
  1586.         out    SOUND_SWITCH, al
  1587.  
  1588. music_exit:    cmp    CS:SONG_FREQUENCY, 1h
  1589.         jne    music_bye
  1590.         in    al, SOUND_SWITCH
  1591.         and    al, 11111100b
  1592.         out    SOUND_SWITCH, al
  1593. music_bye:    pop    si
  1594.         pop    ax
  1595.                 popf
  1596.         ret
  1597.  
  1598. MUSIC        ENDP
  1599. ;------------------------------------------------------------------------------
  1600. ;  TIME : Show current time
  1601. ;------------------------------------------------------------------------------
  1602. TIME        PROC    NEAR
  1603.  
  1604.                 pushf
  1605.         push    ax
  1606.         push    cx
  1607.         push    dx
  1608.         push    ds
  1609.         push    si
  1610.         push    es
  1611.         push    di
  1612.  
  1613.         mov    ax, @code
  1614.         mov    es, ax
  1615.         mov    ds, ax
  1616.         mov    ah, 2ch
  1617.         int    21h
  1618.         xor    ah, ah
  1619.         mov    al, dh
  1620.         push    ax
  1621.         mov    al, cl
  1622.         push    ax
  1623.         mov    al, ch
  1624.         push    ax
  1625.         mov    cx, 3
  1626.  
  1627. trans_again:    mov    ax, OFFSET TIME_TMP
  1628.         mov    si, ax
  1629.         mov    di, ax
  1630.         pop    ax
  1631.         xchg    al, ah
  1632.         call    B2A
  1633.         mov    dx, cx
  1634.         mov    ax, 3
  1635.         sub    ax, dx
  1636.         mov    dx, 6
  1637.         mul    dx
  1638.         mov    dx, OFFSET TIME_STR
  1639.         add    dx, ax
  1640.         mov    di, dx
  1641.         movsb
  1642.         inc    di
  1643.         movsb
  1644.         dec    cx
  1645.         cmp    cx, 0h
  1646.         jg    trans_again
  1647.  
  1648.         lea    si, TIME_STR
  1649.         mov    ax, 1215h            ;ax=(18,21)
  1650.         mov    dx, 1915h            ;dh=(25,21)
  1651.         mov    ch, PUT_MODE
  1652.         mov    cl, 1h
  1653.         call    GPSCR
  1654.  
  1655.         pop    di
  1656.         pop    es
  1657.         pop    si
  1658.         pop    ds
  1659.         pop    dx
  1660.         pop    cx
  1661.         pop    ax
  1662.                 popf
  1663.         ret
  1664.  
  1665. TIME        ENDP
  1666.  
  1667. ;------------------------------------------------------------------------------
  1668. ;  B2A : Binary to ASCII
  1669. ;     Output> es:di(ascii string)  , input> es:di->buffer ah=binary
  1670. ;------------------------------------------------------------------------------
  1671. B2A        PROC    NEAR
  1672.  
  1673.                 pushf
  1674.         push    ax
  1675.         push    bx
  1676.         push    cx
  1677.  
  1678.         cld
  1679.         cmp    ah, 9h                ;if ah >= 9
  1680.         jg    begin                ;  goto begin
  1681.         mov    al, '0'                         ;else
  1682.         stosb                    ;  es:di[0]='0'
  1683. begin:        mov    bl, 0ah             ;initialization
  1684.         mov    cx, 0h
  1685.         mov    al, ah
  1686.         xor    ah, ah
  1687. again:        div    bl                ;al/bl (al=quo,ah=rem)
  1688.         cmp    ax, 0h                ;if ax=0
  1689.         je    done                ;  goto done
  1690.         add    ah, 30h             ;convert num. to char.
  1691.         push    ax
  1692.         inc    cx
  1693.         xor    ah, ah
  1694.         jmp    again
  1695. done:        cmp    cx, 0h
  1696.         je    zero_case
  1697. normal_case:    pop    ax
  1698.         mov    al, ah
  1699.         stosb
  1700.         loop    normal_case
  1701.         jmp    ok
  1702. zero_case:    mov    al, '0'
  1703.         stosb
  1704.  
  1705. ok:        pop    cx
  1706.         pop    bx
  1707.         pop    ax
  1708.                 popf
  1709.         ret
  1710.  
  1711. B2A        ENDP
  1712.  
  1713. ;------------------------------------------------------------------------------
  1714. ;  RUNNING : Show running words
  1715. ;------------------------------------------------------------------------------
  1716. RUNNING     PROC    NEAR
  1717.  
  1718.                 pushf
  1719.         push    ax
  1720.         push    cx
  1721.         push    dx
  1722.         push    ds
  1723.         push    si
  1724.         push    es
  1725.         push    di
  1726.  
  1727.         mov    ax, @code
  1728.         mov    ds, ax
  1729.         mov    es, ax
  1730.         inc    CS:RUN_WORD_COUNT
  1731.         cmp    CS:RUN_WORD_COUNT, 3        ;Judge speed
  1732.         jne    exit_run
  1733.         mov    CS:RUN_WORD_COUNT, 0
  1734.         cmp    CS:RUN_WORD_STRPTR, 389     ;If EOL
  1735.         jl    begin_run
  1736.         mov    CS:RUN_WORD_STRPTR, 0
  1737.  
  1738. begin_run:    push    CS:RUN_WORD_STRPTR
  1739.         pop    CS:RUN_WORD_PTR
  1740.         add    CS:RUN_WORD_STRPTR, 2
  1741.         lea    di, CS:RUN_WORD_STR
  1742.         mov    cx, 20
  1743. run_loop:    cmp    CS:RUN_WORD_PTR, 389        ;If EOL
  1744.         jl    run1
  1745.         mov    CS:RUN_WORD_PTR, 0
  1746. run1:        lea    si, CS:RUN_WORD
  1747.         add    si, CS:RUN_WORD_PTR
  1748.         movsw
  1749.         add    CS:RUN_WORD_PTR, 2
  1750.         loop    run_loop
  1751.  
  1752.         lea    si, CS:RUN_WORD_STR
  1753.         mov    ax, 3918h            ;ax=(57,24)
  1754.         mov    dx, 4c18h            ;dh=(76,24)
  1755.         mov    ch, PUT_MODE
  1756.         mov    cl, 1h
  1757.         call    GPSCR
  1758.  
  1759. exit_run:    pop    di
  1760.         pop    es
  1761.         pop    si
  1762.         pop    ds
  1763.         pop    dx
  1764.         pop    cx
  1765.         pop    ax
  1766.                 popf
  1767.         ret
  1768.  
  1769. RUNNING     ENDP
  1770. ;------------------------------------------------------------------------------
  1771. ;  VIDEO : Get text video address base
  1772. ;------------------------------------------------------------------------------
  1773. VIDEO        PROC    NEAR
  1774.  
  1775.                 pushf
  1776.         push    ax
  1777.         push    bx
  1778.         push    ds
  1779.         mov    ah, 0fh             ;Get video mode
  1780.         int    10h
  1781.         cmp    al, 7h
  1782.         je    mode_7
  1783.         cmp    al, 3h
  1784.         je    mode_3
  1785.         mov    ah, 4ch
  1786.         int    21h
  1787.         mov    ax, @data
  1788.         mov    ds, ax
  1789. mode_3:     mov    CS:VIDEO_BASE, 0b800h
  1790.         jmp    exit_video
  1791. mode_7:     mov    CS:VIDEO_BASE, 0b000h
  1792. exit_video:    pop    ds
  1793.         pop    bx
  1794.         pop    ax
  1795.                 popf
  1796.         ret
  1797.  
  1798. VIDEO        ENDP
  1799.  
  1800. ;-------------------------------------------------------------------------------
  1801. ;  XY2MEM : Transfer xy to mem
  1802. ;        output> ax    , input> ax=(x,y)
  1803. ;-------------------------------------------------------------------------------
  1804. XY2MEM        PROC    NEAR
  1805.  
  1806.                 pushf
  1807.         push    bx
  1808.         push    dx
  1809.                 mov     bx, ax
  1810.         mov    bl, 80
  1811.         mul    bl                ;ax=al*bl  [ax=y*80]
  1812.         mov    bl, bh
  1813.         xor    bh, bh
  1814.         add    ax, bx                ;ax=ax+bx  [ax=80y+x]
  1815.         mov    bl, 2h
  1816.         mul    bx                ;dx:ax=ax*2
  1817.         pop    dx
  1818.         pop    bx
  1819.                 popf
  1820.         ret
  1821.  
  1822. XY2MEM        ENDP
  1823.  
  1824. ;-------------------------------------------------------------------------------
  1825. ;  GPSCR : Get/Put block data from/to screen
  1826. ;       input> ax=(begin_x,begin_y) dx=(end_x,end_y)
  1827. ;          ch=0(GET) ch=1(PUT)  cl=data_group( 1, 2, 3 )
  1828. ;          (GET) es:di->(word)buffer
  1829. ;          (PUT) ds:si->(word)string
  1830. ;-------------------------------------------------------------------------------
  1831. GPSCR        PROC    NEAR
  1832.  
  1833.                 pushf
  1834.         push    bx
  1835.         push    ds
  1836.         push    si
  1837.         push    es
  1838.         push    di
  1839.  
  1840.         cld
  1841.         mov    bl, cl
  1842.         xor    bh, bh
  1843.         mov    CS:GP_MODE[bx], ch
  1844.         mov    CS:BEGIN_X[bx], ah
  1845.         mov    CS:BEGIN_Y[bx], al
  1846.         mov    CS:END_X[bx], dh
  1847.         mov    CS:END_Y[bx], dl
  1848.  
  1849.         mov    cx, ax                ;Initialize couter
  1850.         push    CS:VIDEO_BASE
  1851.         cmp    CS:GP_MODE[bx], GET_MODE    ;What mode ?
  1852.         je    get
  1853.         pop    es                ;put_mode
  1854.         call    XY2MEM                ;  es:di->screen
  1855.         mov    di, ax
  1856.         jmp    if_eol
  1857. get:        pop    ds                ;get_mode
  1858.         call    XY2MEM                ;  ds:si->screen
  1859.         mov    si, ax
  1860. if_eol:     cmp    ch, CS:END_X[bx]        ;if end of line
  1861.         jle    if_end
  1862.         mov    ch, CS:BEGIN_X[bx]        ;  end of line
  1863.         inc    cl
  1864.         inc    CS:BEGIN_Y[bx]
  1865.         mov    ah, CS:BEGIN_X[bx]
  1866.         mov    al, CS:BEGIN_Y[bx]
  1867.         call    XY2MEM
  1868.         cmp    CS:GP_MODE[bx], PUT_MODE
  1869.         je    put
  1870.         mov    si, ax
  1871.         jmp    if_end
  1872. put:        mov    di, ax
  1873. if_end:     cmp    cl, CS:END_Y[bx]
  1874.         jg    exit_gp
  1875. getscr:     movsw
  1876.         inc    ch
  1877.         jmp    if_eol
  1878.  
  1879. exit_gp:    pop    di
  1880.         pop    es
  1881.         pop    si
  1882.         pop    ds
  1883.         pop    bx
  1884.                 popf
  1885.         ret
  1886.  
  1887. GPSCR        ENDP
  1888.  
  1889. ;-------------------------------------------------------------------------------
  1890. ;    STARTUP
  1891. ;-------------------------------------------------------------------------------
  1892. STARTUP     MACRO
  1893.         LOCAL    reget
  1894.  
  1895.                 mov     dx, @code                       ;Prompt your destination
  1896.                 mov     ds, dx
  1897.                 mov     dx, OFFSET CS:MYDST_PMT+2
  1898.                 mov     ah, 9h
  1899.                 int     21h
  1900.  
  1901. reget:          mov     ah, 7h
  1902.                 int     21h
  1903.                 cmp     al, '7'
  1904.                 jg      reget
  1905.                 cmp     al, '0'
  1906.                 jl      reget
  1907.                 mov     CS:MYDST, al
  1908.  
  1909.                 call    VIDEO                           ;Detect video mode
  1910.  
  1911.                 mov     ax, 1010h                       ;Change palete
  1912.                 mov     bh, 0h
  1913.                 mov     ch, 10h
  1914.                 mov     cl, 095h
  1915.                 mov     dh, 80h
  1916.                 int     10h
  1917.  
  1918.                 mov     dx, @data                       ;Change font
  1919.                 mov     es, dx
  1920.                 mov     bp, OFFSET FONT
  1921.                 mov     ah, 11h
  1922.                 mov     al, 10h
  1923.                 mov     bx, 1000h
  1924.                 mov     cx, 7eh
  1925.                 mov     dx, 20h
  1926.                 int     10h
  1927.  
  1928.                 mov     dx, @data                       ;Draw main screen
  1929.                 mov     ds, dx
  1930.         mov    si, OFFSET MAIN_SCR
  1931.         mov    ax, 0h
  1932.         mov    dx, 4f18h
  1933.         mov    ch, PUT_MODE
  1934.         mov    cl, 0h
  1935.         call    GPSCR
  1936.  
  1937.                 mov     es, CS:VIDEO_BASE               ;Show your destination
  1938.                 mov     di, 0c0h
  1939.                 mov     al, CS:MYDST
  1940.                 stosb
  1941.  
  1942.                 mov     dx, 0203h                       ;Place cursor
  1943.                 mov     bh, 0h
  1944.                 mov     ah, 2h
  1945.                 int     10h
  1946.  
  1947.                 mov     dx, 2fbh                        ;Initialize COM2
  1948.                 mov     al, 80h
  1949.                 out     dx, al
  1950.                 mov     dx, 2f8h
  1951.                 mov     al, 0ch
  1952.                 out     dx, al
  1953.                 mov     dx, 2f9h
  1954.                 mov     al, 0h
  1955.                 out     dx, al
  1956.                 mov     dx, 2fbh
  1957.                 mov     al, 3h
  1958.                 out     dx, al
  1959.                 mov     dx, 2f9h
  1960.                 mov     al, 2h
  1961.                 out     dx, al
  1962.                 mov     dx, 2fch
  1963.                 mov     al, 8h
  1964.                 out     dx, al
  1965.  
  1966.                 mov     dx, 3fbh                        ;Initialize COM1
  1967.                 mov     al, 80h
  1968.                 out     dx, al
  1969.                 mov     dx, 3f8h
  1970.                 mov     al, 0ch
  1971.                 out     dx, al
  1972.                 mov     dx, 3f9h
  1973.                 mov     al, 0h
  1974.                 out     dx, al
  1975.                 mov     dx, 3fbh
  1976.                 mov     al, 3h
  1977.                 out     dx, al
  1978.                 mov     dx, 3f9h
  1979.                 mov     al, 1h
  1980.                 out     dx, al
  1981.                 mov     dx, 3fch
  1982.                 mov     al, 8h
  1983.                 out     dx, al
  1984.  
  1985.                 mov     ax, 351ch                       ;Change INT 1C
  1986.                 int     21h
  1987.                 mov     CS:OLD_1C_SEG, es
  1988.                 mov     CS:OLD_1C_OFF, bx
  1989.                 mov     dx, @code
  1990.                 mov     ds, dx
  1991.                 mov     dx, OFFSET CS:NEW_1C
  1992.                 mov     ax, 251ch
  1993.                 int     21h
  1994.  
  1995.                 mov     ax, 3509h                       ;Change INT 9
  1996.         int    21h
  1997.                 mov     CS:OLD_9_SEG, es
  1998.                 mov     CS:OLD_9_OFF, bx
  1999.                 mov     dx, @code
  2000.                 mov     ds, dx
  2001.         mov    dx, OFFSET CS:NEW_9
  2002.         mov    ax, 2509h
  2003.         int    21h
  2004.  
  2005.                 mov     ax, 350bh                       ;Change INT B
  2006.                 int     21h
  2007.                 mov     CS:OLD_B_SEG, es
  2008.                 mov     CS:OLD_B_OFF, bx
  2009.                 mov     dx, @code
  2010.                 mov     ds, dx
  2011.                 mov     dx, OFFSET CS:NEW_B
  2012.                 mov     ax, 250bh
  2013.                 int     21h
  2014.  
  2015.                 mov     ax, 350ch                       ;Change INT C
  2016.                 int     21h
  2017.                 mov     CS:OLD_C_SEG, es
  2018.                 mov     CS:OLD_C_OFF, bx
  2019.                 mov     dx, @code
  2020.                 mov     ds, dx
  2021.                 mov     dx, OFFSET CS:NEW_C
  2022.                 mov     ax, 250ch
  2023.                 int     21h
  2024.  
  2025.                 in      al, PICIMR                      ;Enable COM1 COM2
  2026.                 and     al, 11100111b
  2027.                 out     PICIMR, al
  2028.                 int     0ch
  2029.  
  2030.         ENDM
  2031.  
  2032. ;-------------------------------------------------------------------------------
  2033. ;    SHUTDOWN
  2034. ;-------------------------------------------------------------------------------
  2035. SHUTDOWN    PROC    NEAR
  2036.  
  2037.                 cli
  2038.                 push    ax
  2039.                 push    dx
  2040.                 push    ds
  2041.                 push    si
  2042.  
  2043.                 mov     ds, CS:OLD_1C_SEG               ;Restore INT 1C
  2044.                 mov     dx, CS:OLD_1C_OFF
  2045.                 mov     ax, 251ch
  2046.                 int     21h
  2047.  
  2048.                 mov     ds, CS:OLD_9_SEG                ;Restore INT 9
  2049.         mov    dx, CS:OLD_9_OFF
  2050.         mov    ax, 2509h
  2051.         int    21h
  2052.  
  2053.                 mov     ds, CS:OLD_B_SEG                ;Restore INT B
  2054.                 mov     dx, CS:OLD_B_OFF
  2055.                 mov     ax, 250bh
  2056.                 int     21h
  2057.  
  2058.                 mov     ds, CS:OLD_C_SEG                ;Restore INT C
  2059.                 mov     dx, CS:OLD_C_OFF
  2060.                 mov     ax, 250ch
  2061.                 int     21h
  2062.  
  2063.                 in      al, SOUND_SWITCH                ;Turn off speaker
  2064.                 and     al, 11111100b
  2065.                 out     SOUND_SWITCH, al
  2066.  
  2067.                 cmp     CS:VIDEO_BASE, 0b000h           ;Reset video adapter
  2068.                 je      mode_7
  2069.                 mov     al, 3h
  2070.                 jmp     reset
  2071. mode_7:         mov     al, 7h
  2072. reset:          mov     ah, 0h
  2073.                 int     10h
  2074.  
  2075.                 pop     si
  2076.                 pop     ds
  2077.                 pop     dx
  2078.                 pop     ax
  2079.                 sti
  2080.         ret
  2081.  
  2082. SHUTDOWN    ENDP
  2083.  
  2084. ;-------------------------------------------------------------------------------
  2085. ;    MAIN
  2086. ;-------------------------------------------------------------------------------
  2087. main_begin:    STARTUP
  2088. idle:        jmp    idle
  2089.         end    main_begin
  2090.  
  2091.